Bad C influence

djberg96 on 2002-11-26T20:23:28

Note to self: '\0' and "\0" are not the same thing.

That little mistake accounts for 99% of the difference in output size I was getting between my own program and an equivalent Perl program that simply writes "Hello" to cell 0,0 in a single spreadsheet.

I'm sure tracking down the remaining 12 byte discrepency will be about as much fun as pulling my fingernails off with a pliers.


cgi-lib

Ovid on 2002-11-26T21:06:54

The Perl4 cgi-lib had the "null byte" problem in various versions of the library. Usually, people wouldn't notice when dealing with single values for a form param, but cgi-lib would separate multiple values with the ASCII zero and expect people to split on them. Needless to say, using '\0' to separate those values would produce somewhat disappointing results.