Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!usc!snorkelwacker.mit.edu!bloom-beacon!eru!hagbard!sunic!mcsun!cernvax!chx400!chx400!ugun2b!ugsc2a!fisher From: fisher@sc2a.unige.ch Newsgroups: comp.os.msdos.programmer Subject: Re: Novell mapped drives Message-ID: <1991Mar23.144335.393@sc2a.unige.ch> Date: 23 Mar 91 12:43:35 GMT References: <12106@pasteur.Berkeley.EDU> Organization: University of Geneva, Switzerland Lines: 40 In article <12106@pasteur.Berkeley.EDU>, stevew@tureen.Berkeley.EDU (Stephen Williams) writes: > [...] > How then, can I differentiate between actual physical drives and Novell's > mapped drives? I'd like to be able to do this from Turbo C, of course. Will > I need some kind of Novell library, or can I figure it out some other way? This is a function taken from "write.c" in "mfwrite.zoo" posted in cbip this year and archived in Simtel20 (don't know exact location, it's a batch utility): void getpath(void) /* * Stores the current path into `path' and the true path into `true_path'. * The true path is obtaind by the dos function call 0x60. * DS:SI is input path; ES:DI is output path. */ { union REGS r; struct SREGS s; if (*path != '\0') /* i.e. second call */ return; getcwd (path, MAXPATH); r.x.ax = 0x6000; /* assuming near pointers: */ r.x.si = (unsigned)path; r.x.di = (unsigned)true_path; segread(&s); s.es = s.ds; intdosx(&r,&r,&s); } If the string in "true_path" starts with "\\" ("\\\\" in c-notation), then you are dealing with a (novell) network path. If not, different strings mean either joined or subst'ed drives. Good luck, Markus Fischer, Dpt of Anthropology, Geneva CH