X-Authentication-Warning: delorie.com: mail set sender to djgpp-bounces using -f X-Received: by 10.182.63.17 with SMTP id c17mr11004205obs.13.1428392656442; Tue, 07 Apr 2015 00:44:16 -0700 (PDT) X-Received: by 10.140.93.226 with SMTP id d89mr144468qge.38.1428392656327; Tue, 07 Apr 2015 00:44:16 -0700 (PDT) Newsgroups: comp.os.msdos.djgpp Date: Tue, 7 Apr 2015 00:44:16 -0700 (PDT) Complaints-To: groups-abuse AT google DOT com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=193.248.181.231; posting-account=mT4CwQoAAACeGCTFZdO8LdCOEWAuVBL8 NNTP-Posting-Host: 193.248.181.231 User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: Subject: I have found fopen() + network bug From: =?ISO-8859-1?Q?S=E9bastien_Favier?= Injection-Date: Tue, 07 Apr 2015 07:44:16 +0000 Content-Type: text/plain; charset=ISO-8859-1 Bytes: 2408 Lines: 45 To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from quoted-printable to 8bit by delorie.com id t37804u3025248 Reply-To: djgpp AT delorie DOT com Hi everybody, hi DJ! I have found a bug with fopen() function when I want to open a shared file Wireshark : http://cpcdos.e-monsite.com/medias/files/fopen-freedos.png For open test.cpc : - With a normal request (Windows, EDIT.COM(dos), Command.com(dos), or other..) he send 0x0021 request ( offset:0x5D & 0x5E ) (Read only+Archive attribute), so he want open a file, OK ! - With a fopen request he send 0x0017 request ( offset:0x5D & 0x5E ) SO he want search a directory (+hidden, readonly+system attribute) but no a file. BAD! There are solution for "force" fopen to open/search a file in my path string(char)? add "\n" ? Best regards Sébastien FAVIER PS: - I use GCC 4.7.3 / DJGPP for dos (Under FreeDos) - I have all permissions - I have test multiple combinaisons : fopen("x:\myfile.abc, "r"); fopen("x:\\myfile.abc, "r"); fopen("x:/myfile.abc, "r"); fopen("x://myfile.abc, "r"); Or directly with server name : fopen("\\MyServer\myfile.abc, "r"); fopen("\\\\MyServer\\myfile.abc, "r"); fopen("\\MyServer/myfile.abc, "r"); fopen("\\\\MyServer//myfile.abc, "r"); fopen("//MyServer/myfile.abc, "r"); fopen("////MyServer//myfile.abc, "r"); fopen("//MyServer\myfile.abc, "r"); fopen("////MyServer\\myfile.abc, "r"); No success.. :-(