Strange Problem calling chdir()

Peter Mueller peter.o.mueller at gmx.de
Mon Dec 30 17:47:17 UTC 2002


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi Gregm,

I can debug (step) into chdir().

Peter

On Mon, 30 Dec 2002 11:06:53 -0500 (EST)
gregory.menke at gsfc.nasa.gov wrote:

> 
> Peter Mueller writes:
>  > -----BEGIN PGP SIGNED MESSAGE-----
>  > Hash: SHA1
>  > 
>  > Hello all,
>  > 
>  > I have a strange problem with the code shown below. In
>  > dummyHMI::test() argc/argv are in reality built from
>  > commands/parameters I get from a serial line. The problem is that the
>  > name holds "test" as expected in dummyClient::printdir(), but is
>  > empty in chdir().
>  > 
> 
> Barring some subtle bug, my guess is the chdir() is being optimized
> away since you're not doing anything with res.  Try declaring res,
> then assigning chdir's return value to it on a separate line.
> 
> Gregm
> 


- -- 
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.7 (GNU/Linux)

iD8DBQE+EIalUzCcwYQMTJoRAnM7AJ48mSG35pUYcbMUhD/G7vj82iOwswCgvkI/
Pb3RwuGKiI9aiKFZY8lg6iI=
=aiMF
-----END PGP SIGNATURE-----



More information about the users mailing list