Subject: wxwin port (fopen problem)
From: [email-masked] (Keith Gary Boyce)

25 Oct 1996 23:57:41 -0700
Sender: [email-masked]
Approved: [email-masked]
Distribution: cygnus
Message-ID: <[email-masked]>
Mime-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII
Original-To: [email-masked]
Original-Cc: Geoffrey Noer <[email-masked]>, Julian Smart <[email-masked]>
X-PRIORITY: 3 (Normal)
X-Mailer: Chameleon 5.0, TCP/IP for Windows, NetManage Inc.
Original-Sender: [email-masked]

Hi folks if anyone has any idea why fopen in backtrace below
returns 0 when file it is attempting to open exists, then please
let me know.

1139      char *actual_file = copystring(filename);
Value returned is $1 = 0xd6a844 
"C:\\usr\\garp\\src\\wxwin\\utils\\prologio\\doc
s\\badcase.txt"
(gdb) step
1141      Unix2DosFilename(actual_file);
(gdb)
wxUnix2DosFilename (
    s=0xd6a844 
"C:\\usr\\garp\\src\\wxwin\\utils\\prologio\\docs\\badcase.txt")
    at wb_utils.cpp:918
918       if (s)
(gdb) finish
Run till exit from #0  wxUnix2DosFilename (
    s=0xd6a844 
"C:\\usr\\garp\\src\\wxwin\\utils\\prologio\\docs\\badcase.txt")
    at wb_utils.cpp:918
0x40c703 in PrologDatabase::ReadProlog (this=0x4bb000,
    filename=0x4b8af8 
"C:\\usr\\garp\\src\\wxwin\\utils\\prologio\\docs\\badcase
..txt") at read.cpp:1141
1141      Unix2DosFilename(actual_file);
(gdb) step
1144      FILE *f = fopen(actual_file, "r");
(gdb) print actual_file
$2 = 0xd6a844 
"C:\\usr\\garp\\src\\wxwin\\utils\\prologio\\docs\\badcase.txt"
(gdb) step
fopen (
    file=0xd6a844 
"C:\\usr\\garp\\src\\wxwin\\utils\\prologio\\docs\\badcase.txt
", mode=0x40c6d4 "r")
    at 
.../../../../../../packages/libs/newlib/libc/stdio/fopen.c:162
.../../../../../../packages/libs/newlib/libc/stdio/fopen.c:162: No 
such file or d
irectory.
Current language:  auto; currently c
(gdb) finish
Run till exit from #0  fopen (
    file=0xd6a844 
"C:\\usr\\garp\\src\\wxwin\\utils\\prologio\\docs\\badcase.txt
", mode=0x40c6d4 "r")
    at 
.../../../../../../packages/libs/newlib/libc/stdio/fopen.c:162
0x40c714 in PrologDatabase::ReadProlog (this=0x4bb000,
    filename=0x4b8af8 
"C:\\usr\\garp\\src\\wxwin\\utils\\prologio\\docs\\badcase
..txt") at read.cpp:1144
1144      FILE *f = fopen(actual_file, "r");
Value returned is $3 = (struct __sFILE *) 0x0
Current language:  auto; currently c++
1145      if (f)
(gdb)
1157        delete actual_file;
(gdb)
1158        return FALSE;
(gdb)
1160    }
(gdb)

-------------------------------------
Name: Garry Boyce
E-mail: [email-masked] (Garry Boyce)
Date: 12/01/94
Time: 08:46:10

This message was sent by Chameleon 
-------------------------------------

-
For help on using this list, send a message to
"[email-masked]" with one line of text: "help".