Bug #887 [Com]: Dosn't work at all ;-) Forget O_BINARY

From: Date: Fri, 03 Mar 2023 16:28:18 +0000
Subject: Bug #887 [Com]: Dosn't work at all ;-) Forget O_BINARY
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-243842@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=887&edit=1 ID: 887 Comment by: amanda at mail dot com Reported by: edetocquev at teaser dot fr Summary: Dosn't work at all ;-) Forget O_BINARY Status: Closed Type: Bug Package: dBase related Operating System: Windows 95 PHP Version: 3.0.5 Block user comment: N Private report: N New Comment: not working still (https://aimproviderportals.com)github.com Previous Comments: ------------------------------------------------------------------------ [1998-11-23 01:07:50] jim Fix commited to CVS. Thanks for the hint. ------------------------------------------------------------------------ [1998-10-31 19:56:10] edetocquev at teaser dot fr There is a little bug in dbase function (dbase_create and dbase_open) when running PHP on Windows 95. Those functions open the file without the flag O_BINARY=0x8000 and dbase file are binary files. So when a record is added, the database is definitively corrupted. I have found that I can pass 0x8002 to dbase_open, but there is no way to make dbase_create working properly, so I have had to modify the php3_dbase.dll. But I think it's better to correct the bug ;-) This append possibly on others database functions type, but I had tested only this one. For example : ========= php-3.0.5/functions/dbase.c:500 if ((fd = open(filename->value.str.val, #if (WIN32|WINNT) O_BINARY| #endif O_RDWR|O_CREAT, 0644)) < 0) { ========= php-3.0.5/dbase/dbf_head.c:229 #if (WIN32|WINNT) o_flags |= O_BINARY; #endif if ((fd = open(cp, o_flags)) < 0) { ------------------------------------------------------------------------ -- Edit this bug report at https://bugs.php.net/bug.php?id=887&edit=1

« previous php.bugs (#243842) next »