Path: utzoo!telly!ddsw1!lll-winken!killer!mit-eddie!bloom-beacon!tut.cis.ohio-state.edu!ATHENA.MIT.EDU!raeburn From: raeburn@ATHENA.MIT.EDU (Ken Raeburn) Newsgroups: gnu.gcc.bug Subject: Re: core dumper under GCC 1.30 Message-ID: <8810191923.AA25556@MULTICS.MIT.EDU> Date: 19 Oct 88 19:23:42 GMT Sender: daemon@tut.cis.ohio-state.edu Distribution: gnu Organization: GNUs Not Usenet Lines: 23 The problem you describe stems from the fact that sscanf (at least in some stdio implementations) wants to write into one of the strings passed. The dpANS C spec says that literal string arguments are not writable; therefore the string that sscanf tries to write is not in a writable portion of the program image. This problem is listed in the GNU CC documentation, in the section "Incompatibilities of GNU CC". Try either doing something like main () { int y, m, d; char format[] = "%d"; /* ... */ sscanf (&date[7], format, &y); /* ... */ } (preferable) or compiling with "-fwritable-strings". -- Ken