Lines Matching refs:file

5 /* Try reading some or all content of the file opened in write only mode */
7 // include the file.inc for common functions for test
8 include ("file.inc");
11 Description : Read data from file of size $read_size and verifies that $expected_size no. of
19 // print file pointer position before read
24 echo "Reading $read_size bytes from file, expecting $expect_size bytes ... ";
31 echo "Error reading file, total number of bytes read = ".strlen($data_from_file)."\n";
33 // file pointer position after read
35 // check if file pointer at eof()
51 echo "\n-- Testing fread() with file having content of type ". $file_content_type ." --\n";
53 /* open the file using $files_modes and perform fread() on it */
60 … $filename = __DIR__."/fread_variation2.tmp"; // this is name of the file created by create_files()
64 echo "Error: failed to fopen() file: $filename!";
73 echo "-- Reading entire file content, expected : 0 bytes --\n";
74 // read from file, by giving the file actual size,
80 // reading file by giving less than its size
81 echo "-- Reading file content less than max. file size, expected : 0 bytes --\n";
88 // now close the file
91 // delete the file created
92 delete_file($filename); // delete file
101 -- Testing fread() with file having content of type numeric --
103 -- Reading entire file content, expected : 0 bytes --
106 Reading 1024 bytes from file, expecting 0 bytes ...
107 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
112 -- Reading file content less than max. file size, expected : 0 bytes --
115 Reading 1000 bytes from file, expecting 0 bytes ...
116 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
122 -- Reading entire file content, expected : 0 bytes --
125 Reading 1024 bytes from file, expecting 0 bytes ...
126 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
131 -- Reading file content less than max. file size, expected : 0 bytes --
134 Reading 1000 bytes from file, expecting 0 bytes ...
135 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
141 -- Reading entire file content, expected : 0 bytes --
144 Reading 1024 bytes from file, expecting 0 bytes ...
145 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
150 -- Reading file content less than max. file size, expected : 0 bytes --
153 Reading 1000 bytes from file, expecting 0 bytes ...
154 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
160 -- Reading entire file content, expected : 0 bytes --
163 Reading 1024 bytes from file, expecting 0 bytes ...
164 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
169 -- Reading file content less than max. file size, expected : 0 bytes --
172 Reading 1000 bytes from file, expecting 0 bytes ...
173 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
179 -- Reading entire file content, expected : 0 bytes --
182 Reading 1024 bytes from file, expecting 0 bytes ...
183 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
188 -- Reading file content less than max. file size, expected : 0 bytes --
191 Reading 1000 bytes from file, expecting 0 bytes ...
192 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
198 -- Reading entire file content, expected : 0 bytes --
201 Reading 1024 bytes from file, expecting 0 bytes ...
202 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
207 -- Reading file content less than max. file size, expected : 0 bytes --
210 Reading 1000 bytes from file, expecting 0 bytes ...
211 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
217 -- Reading entire file content, expected : 0 bytes --
220 Reading 1024 bytes from file, expecting 0 bytes ...
221 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
226 -- Reading file content less than max. file size, expected : 0 bytes --
229 Reading 1000 bytes from file, expecting 0 bytes ...
230 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
236 -- Reading entire file content, expected : 0 bytes --
239 Reading 1024 bytes from file, expecting 0 bytes ...
240 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
245 -- Reading file content less than max. file size, expected : 0 bytes --
248 Reading 1000 bytes from file, expecting 0 bytes ...
249 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
255 -- Reading entire file content, expected : 0 bytes --
258 Reading 1024 bytes from file, expecting 0 bytes ...
259 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
264 -- Reading file content less than max. file size, expected : 0 bytes --
267 Reading 1000 bytes from file, expecting 0 bytes ...
268 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
274 -- Testing fread() with file having content of type text --
276 -- Reading entire file content, expected : 0 bytes --
279 Reading 1024 bytes from file, expecting 0 bytes ...
280 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
285 -- Reading file content less than max. file size, expected : 0 bytes --
288 Reading 1000 bytes from file, expecting 0 bytes ...
289 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
295 -- Reading entire file content, expected : 0 bytes --
298 Reading 1024 bytes from file, expecting 0 bytes ...
299 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
304 -- Reading file content less than max. file size, expected : 0 bytes --
307 Reading 1000 bytes from file, expecting 0 bytes ...
308 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
314 -- Reading entire file content, expected : 0 bytes --
317 Reading 1024 bytes from file, expecting 0 bytes ...
318 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
323 -- Reading file content less than max. file size, expected : 0 bytes --
326 Reading 1000 bytes from file, expecting 0 bytes ...
327 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
333 -- Reading entire file content, expected : 0 bytes --
336 Reading 1024 bytes from file, expecting 0 bytes ...
337 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
342 -- Reading file content less than max. file size, expected : 0 bytes --
345 Reading 1000 bytes from file, expecting 0 bytes ...
346 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
352 -- Reading entire file content, expected : 0 bytes --
355 Reading 1024 bytes from file, expecting 0 bytes ...
356 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
361 -- Reading file content less than max. file size, expected : 0 bytes --
364 Reading 1000 bytes from file, expecting 0 bytes ...
365 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
371 -- Reading entire file content, expected : 0 bytes --
374 Reading 1024 bytes from file, expecting 0 bytes ...
375 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
380 -- Reading file content less than max. file size, expected : 0 bytes --
383 Reading 1000 bytes from file, expecting 0 bytes ...
384 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
390 -- Reading entire file content, expected : 0 bytes --
393 Reading 1024 bytes from file, expecting 0 bytes ...
394 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
399 -- Reading file content less than max. file size, expected : 0 bytes --
402 Reading 1000 bytes from file, expecting 0 bytes ...
403 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
409 -- Reading entire file content, expected : 0 bytes --
412 Reading 1024 bytes from file, expecting 0 bytes ...
413 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
418 -- Reading file content less than max. file size, expected : 0 bytes --
421 Reading 1000 bytes from file, expecting 0 bytes ...
422 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
428 -- Reading entire file content, expected : 0 bytes --
431 Reading 1024 bytes from file, expecting 0 bytes ...
432 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
437 -- Reading file content less than max. file size, expected : 0 bytes --
440 Reading 1000 bytes from file, expecting 0 bytes ...
441 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
447 -- Testing fread() with file having content of type text_with_new_line --
449 -- Reading entire file content, expected : 0 bytes --
452 Reading 1024 bytes from file, expecting 0 bytes ...
453 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
458 -- Reading file content less than max. file size, expected : 0 bytes --
461 Reading 1000 bytes from file, expecting 0 bytes ...
462 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
468 -- Reading entire file content, expected : 0 bytes --
471 Reading 1024 bytes from file, expecting 0 bytes ...
472 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
477 -- Reading file content less than max. file size, expected : 0 bytes --
480 Reading 1000 bytes from file, expecting 0 bytes ...
481 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
487 -- Reading entire file content, expected : 0 bytes --
490 Reading 1024 bytes from file, expecting 0 bytes ...
491 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
496 -- Reading file content less than max. file size, expected : 0 bytes --
499 Reading 1000 bytes from file, expecting 0 bytes ...
500 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
506 -- Reading entire file content, expected : 0 bytes --
509 Reading 1024 bytes from file, expecting 0 bytes ...
510 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
515 -- Reading file content less than max. file size, expected : 0 bytes --
518 Reading 1000 bytes from file, expecting 0 bytes ...
519 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
525 -- Reading entire file content, expected : 0 bytes --
528 Reading 1024 bytes from file, expecting 0 bytes ...
529 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
534 -- Reading file content less than max. file size, expected : 0 bytes --
537 Reading 1000 bytes from file, expecting 0 bytes ...
538 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
544 -- Reading entire file content, expected : 0 bytes --
547 Reading 1024 bytes from file, expecting 0 bytes ...
548 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
553 -- Reading file content less than max. file size, expected : 0 bytes --
556 Reading 1000 bytes from file, expecting 0 bytes ...
557 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
563 -- Reading entire file content, expected : 0 bytes --
566 Reading 1024 bytes from file, expecting 0 bytes ...
567 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
572 -- Reading file content less than max. file size, expected : 0 bytes --
575 Reading 1000 bytes from file, expecting 0 bytes ...
576 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
582 -- Reading entire file content, expected : 0 bytes --
585 Reading 1024 bytes from file, expecting 0 bytes ...
586 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
591 -- Reading file content less than max. file size, expected : 0 bytes --
594 Reading 1000 bytes from file, expecting 0 bytes ...
595 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
601 -- Reading entire file content, expected : 0 bytes --
604 Reading 1024 bytes from file, expecting 0 bytes ...
605 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
610 -- Reading file content less than max. file size, expected : 0 bytes --
613 Reading 1000 bytes from file, expecting 0 bytes ...
614 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
620 -- Testing fread() with file having content of type alphanumeric --
622 -- Reading entire file content, expected : 0 bytes --
625 Reading 1024 bytes from file, expecting 0 bytes ...
626 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
631 -- Reading file content less than max. file size, expected : 0 bytes --
634 Reading 1000 bytes from file, expecting 0 bytes ...
635 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
641 -- Reading entire file content, expected : 0 bytes --
644 Reading 1024 bytes from file, expecting 0 bytes ...
645 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
650 -- Reading file content less than max. file size, expected : 0 bytes --
653 Reading 1000 bytes from file, expecting 0 bytes ...
654 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
660 -- Reading entire file content, expected : 0 bytes --
663 Reading 1024 bytes from file, expecting 0 bytes ...
664 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
669 -- Reading file content less than max. file size, expected : 0 bytes --
672 Reading 1000 bytes from file, expecting 0 bytes ...
673 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
679 -- Reading entire file content, expected : 0 bytes --
682 Reading 1024 bytes from file, expecting 0 bytes ...
683 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
688 -- Reading file content less than max. file size, expected : 0 bytes --
691 Reading 1000 bytes from file, expecting 0 bytes ...
692 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
698 -- Reading entire file content, expected : 0 bytes --
701 Reading 1024 bytes from file, expecting 0 bytes ...
702 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
707 -- Reading file content less than max. file size, expected : 0 bytes --
710 Reading 1000 bytes from file, expecting 0 bytes ...
711 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
717 -- Reading entire file content, expected : 0 bytes --
720 Reading 1024 bytes from file, expecting 0 bytes ...
721 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
726 -- Reading file content less than max. file size, expected : 0 bytes --
729 Reading 1000 bytes from file, expecting 0 bytes ...
730 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
736 -- Reading entire file content, expected : 0 bytes --
739 Reading 1024 bytes from file, expecting 0 bytes ...
740 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
745 -- Reading file content less than max. file size, expected : 0 bytes --
748 Reading 1000 bytes from file, expecting 0 bytes ...
749 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
755 -- Reading entire file content, expected : 0 bytes --
758 Reading 1024 bytes from file, expecting 0 bytes ...
759 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
764 -- Reading file content less than max. file size, expected : 0 bytes --
767 Reading 1000 bytes from file, expecting 0 bytes ...
768 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
774 -- Reading entire file content, expected : 0 bytes --
777 Reading 1024 bytes from file, expecting 0 bytes ...
778 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d
783 -- Reading file content less than max. file size, expected : 0 bytes --
786 Reading 1000 bytes from file, expecting 0 bytes ...
787 Notice: fread(): Read of 8192 bytes failed with errno=9 Bad file descriptor in %s on line %d