weird chdir/getcwd behaviour with qnet mount directory

Hello!

I’m trying to chdir to “/net” directory and get the current working
directory.
I get error “bad file descriptor” from getcwd().

and if I try:
system( “cd /net && pwd” );
that works correclty

testing code is here: ftp://ftp.qnx.org.ru/pub/projects/dmi/chdirnet.tar.gz

Regards,
Dmitry