ID: 45102 Comment by: pg23193+php at sgh dot waw dot pl Reported By: Eugene dot Migalin at pcmp dot ru Status: Open Bug Type: dBase related Operating System: Linux (Fedora 8) PHP Version: 5.2.6 New Comment:
Dbase file header gets corrupted like in #42261 Previous Comments: ------------------------------------------------------------------------ [2008-05-27 05:27:13] Eugene dot Migalin at pcmp dot ru Description: ------------ after putting data into a dbase file using function dbase_add_record() the dbase file gets corrupted. The bug has been located in php-5.2.6/ext/dbase/dbf_head.c at: 1. line 202: shoud be dbfield.dbf_flen[0] = 8; dbfield.dbf_flen[1] = 0; as is dbf->db_flen = 8; 2. line 205: shoud be dbfield.dbf_flen[0] = 1; dbfield.dbf_flen[1] = 0; as is dbf->db_flen = 1; Reproduce code: --------------- any code using dbase_add_record() with a dbase file containing Date or(and) Logical fields ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=45102&edit=1