Thread overview
newbie question
Dec 13, 2003
Gerd Schering
Dec 14, 2003
Andrew Edwards
Dec 14, 2003
Ant
Dec 15, 2003
Gerd Schering
Dec 19, 2003
Walter
December 13, 2003
Hello,

I wrote the following little program, just to get aquainted with D:

void
main ()
{

char[] dirname = "Newdir";

mkdir(dirname);
}

The programm compliles without error, but when I run it, it says:

Error: Newdir: 0

The directory get's created. Any hint?

Gerd


December 14, 2003
"Gerd Schering" <Gerd_member@pathlink.com> wrote in message news:brg0jk$2ifc$1@digitaldaemon.com...
> Hello,
>
> I wrote the following little program, just to get aquainted with D:
>
> void
> main ()
> {
>
> char[] dirname = "Newdir";
>
> mkdir(dirname);
> }
>
> The programm compliles without error, but when I run it, it says:
>
> Error: Newdir: 0
>
> The directory get's created. Any hint?
>
> Gerd
>
>

What system are you using? This works just fine on WinXP Pro.


December 14, 2003
In article <brg0jk$2ifc$1@digitaldaemon.com>, Gerd Schering says...
>
>Hello,
>
>I wrote the following little program, just to get aquainted with D:
>
>void
>main ()
>{
>
>char[] dirname = "Newdir";
>
>mkdir(dirname);
>}
>
>The programm compliles without error, but when I run it, it says:
>
>Error: Newdir: 0
>
>The directory get's created. Any hint?
>
>Gerd
>
>

I that the linux version?

Some file functions on the linux version throw an error when the system call returns normally, because they check for the wrong return code. seems create dir is one of those.

(this error was reported before)

You could wait for the next release or just go there an correct you local version of phobos.

look for a bug report I posted on this news group.

Ant


December 15, 2003
In article <bri06v$2ca0$1@digitaldaemon.com>, Ant says...

[...]
>>The programm compliles without error, but when I run it, it says:
>>
>>Error: Newdir: 0
>>
>>The directory get's created. Any hint?
>>

>
>I that the linux version?
>
>Some file functions on the linux version throw an error when the system call returns normally, because they check for the wrong return code. seems create dir is one of those.
>

Well, it is the linux version....


December 19, 2003
"Gerd Schering" <Gerd_member@pathlink.com> wrote in message news:brkbqs$2p8m$1@digitaldaemon.com...
> Well, it is the linux version....

It's a known bug, and it'll get fixed in the next update. -Walter