From: Eli Zaretskii Newsgroups: comp.os.msdos.djgpp Subject: Re: Simple MKDIR problem Date: Sun, 10 Oct 1999 13:11:55 +0200 Organization: NetVision Israel Lines: 25 Message-ID: References: <37FE2700 DOT 9875C024 AT pd DOT jaring DOT my> <37FE5353 DOT A35D60A3 AT hmc DOT edu> NNTP-Posting-Host: is.elta.co.il Mime-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Trace: news.netvision.net.il 939553840 15188 199.203.121.2 (10 Oct 1999 11:10:40 GMT) X-Complaints-To: abuse AT netvision DOT net DOT il NNTP-Posting-Date: 10 Oct 1999 11:10:40 GMT X-Sender: eliz AT is In-Reply-To: <37FE5353.A35D60A3@hmc.edu> To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com X-Mailing-List: djgpp AT delorie DOT com X-Unsubscribes-To: listserv AT delorie DOT com Precedence: bulk On Fri, 8 Oct 1999, Nate Eldredge wrote: > dsk wrote: > > > > Here's the simple code > > > > void _mkdir(char *dir) > > { > > _REGS r; > > r.h.ah = 0x39; > > r.x.ds = (ulong)(dir) >> 16; > > r.x.dx = (ulong)(dir) & 15; > > _int(0x21, r); > > printf("\nError number: %d %s", r.x.ax); > > } > > > > When I ran it _mkdir("c:\\test\\somethin"), it just return error 3 (path > > not found). Why?? > > Read FAQ sections 18.2 and 18.4. And, in this case, you could also look at the source of mkdir in the DJGPP library (djlsr202.zip, file src/libc/posix/sys/stat/mkdir.c), which shows how this *should* be done.