I'm trying to compile a C program that I wrote on a Sun system
but it won't work.  The code compiles and runs fine on the
Sun server.  However, when I copy the code to my linux box
(RH 6.0) from the Sun system via ftp and then try to work
with it I have all kinds of problems. I can compile the
code but the program causes a core dump when run.  Using
Code Medic,  these are the two error messages I come across
(one or the other but not both at the same time):

1)
Program received signal SIGSEGV Segmentation fault.
0x40075027 in strlen (str = 0x0 ) at ../sysdeps/i386/strlen.c:27
../sysdeps/i386/strlen.c:27 No such file or directory.

2)
#0 strcpy (dest=0xbffff9e4 "É", src= 0x0) at ../sysdeps/generic/strcpy.c:37
../sysdeps/generic/strcpy.c:37: No such file or directory

The code is ANSI C compliant and contains no fancy tricks and nothing
system dependant.

Once or twice I managed to get the program to run but then
it would crash if I edited then recompiled it.

Now for a twist.  If I create a program directly on my linux system,
everthing works fine, no errors at all.

I'm using GNU gcc-2.95.2 on the linux box.  I'm not sure of the version
on the UNIX system.

I'm starting to wonder if there are hidden charaters or
something in the file format (ie. linux format vs unix vs dos)
that could be causing the problem.

Anyone have any ideas?

I want to be able to store the code in one location (the space allocated to
 me by my ISP) and ftp it to where ever I happen to be. ie. copy it the SUN
system and work on it there then copy it to the ISP then my linux system and
work on it there.

Thanks in advance.



-- 
To unsubscribe: mail [EMAIL PROTECTED] with "unsubscribe"
as the Subject.

Reply via email to