]> granicus.if.org Git - php/commitdiff
Add a testcase for this bug
authorMelvyn Sopacua <msopacua@php.net>
Thu, 5 Dec 2002 19:29:45 +0000 (19:29 +0000)
committerMelvyn Sopacua <msopacua@php.net>
Thu, 5 Dec 2002 19:29:45 +0000 (19:29 +0000)
ext/standard/tests/file/bug12556.phpt [new file with mode: 0644]

diff --git a/ext/standard/tests/file/bug12556.phpt b/ext/standard/tests/file/bug12556.phpt
new file mode 100644 (file)
index 0000000..b673d41
--- /dev/null
@@ -0,0 +1,21 @@
+--TEST--
+Bug #12556: fgetcvs ignores lengths when quotes not closed
+--POST--
+--GET--
+--FILE--
+<?php
+$fp=fopen(dirname(__FILE__)."/test.csv", "r");
+while($line=fgetcsv($fp, 24)){
+       print("Read 24 bytes\n");
+}
+?>
+--EXPECT--
+Read 24 bytes
+Read 24 bytes
+Read 24 bytes
+Read 24 bytes
+Read 24 bytes
+Read 24 bytes
+Read 24 bytes
+Read 24 bytes
+Read 24 bytes