Date: Fri, 10 Mar 1995 13:09:03 +0800 From: pattabhi AT la DOT tce DOT com (Pattabhi Attaluri) To: djgpp AT sun DOT soe DOT clarkson DOT edu Subject: Segmentation Violation... I have a program compiled with djgpp 1.12m4, using gcc-2.6.0. When I run my program in a DOS box under Windows it works, but under plain DOS it crashes. Another strange behaviour is that it works under plain DOS if I run it from my local disk instead of network. Does anybody know what could be the problem ? The program always crashes at the same place, in __doprnt, but the fprintf calling it seems correct. My feeling is that somehow some memory gets corrupted (?). One thing which is worth mentioning is that my program spawns another program, and the crash occurs just after the spawn. The following shows more info. Regards, Pattabhi. The output of go32 command without any parameters is: n:\djgpp\src\gcc-260\ocode\djgpp>go32 go32 version 1.12.maint3 Copyright (C) 1994 DJ Delorie Lowest version I can run is 1.08 go32.exe usage: go32 [-d {debugger}] [{program} [{options} . . . ]] go32.exe build time was Sun Dec 18 16:36:42 1994 VCPI (Expanded) memory available: 14992 Kb Swap space available: 72400 Kb The entries in my config.sys file are: DEVICE=C:\DOS\HIMEM.SYS DEVICE=C:\DOS\EMM386.EXE RAM FRAME=NONE BUFFERS=80,0 FILES=150 DOS=UMB LASTDRIVE=Z FCBS=16,8 DEVICEHIGH /L:1,12048 =C:\DOS\SETVER.EXE DOS=HIGH STACKS=9,256 shell=c:\dos\command.com c:\dos\ /E:16384 /P DEVICEHIGH /L:1,74304 =C:\NFS\PCNFS.SYS /F120 DEVICEHIGH /L:2,1408 =C:\NFS\SOCKDRV.SYS DEVICE=C:\LANMAN\PROTMAN.SYS /I:C:\LANMAN DEVICEHIGH /L:1,7568 =C:\LANMAN\NFS-NDIS.SYS DEVICEHIGH /L:1,15312 =C:\LANMAN\ELNK3.DOS I defined the following environment variables: TEMP=C:\tmp TMPDIR=c:\tmp TMP=C:\tmp\ DJGPP=n:/djgpp/djgpp.env GO32TMP=c:\tmp PATH=n:\djgpp\bin;C:\GNU;C:\UTIL;C:\NFS;C:\WINDOWS;C:\DOS; GO32=topline