Red Hat axp-list: Linux on Alpha (1995-2022)
 help / color / mirror / Atom feed
From: Fred Roy <froy@gr.osf.org>
Subject: Re: I really don't know
Date: Wed, 04 Sep 1996 10:26:34 +0200	[thread overview]
Message-ID: <4b8a1b5f81e86c17825f193e194b0626.axp-list@archive.invalid> (raw)
In-Reply-To: <199609040317.WAA07561@saratoga.compassnet.com>

Hello Brian,
I think I can answer to your questions:

> 1. What does " passing arg1 of xxxx from incompatible pointer type" mean 
> exactly, the way I understand it, it has to do with a 32 bit number?????
> It should occur in something like:
	/* 1.a */
	int *a;
	extern int xxxx(char *b);
	main() { xxxx(a) }; /* here [int != char] */
Note that function xxxx might have been defined by a system header file 
included
by your program. E.g.:
	/* 1.b */
	#include <time.h>	/* this header defines time_t and time() */
	long *tp;
	main() { time(tp); }	/* here [time_t != long] */

> 2. What is the best way to figure out this memory violation?
> diald: memory violation at pc=155556be3cc rp=120009770 (bad address = 
> 00000000)
> Segmentation fault (core dumped)

A way is to compile your application with the option "-g", then to run it 
under a debugger such as gdb. Do "man gdb" for details. The example 1.a of 
source code given above is likely to abort with a "Segmentation fault", 
because pointer a was not initialized.
 
fred

email: froy@gr.osf.org -- www: http://www.osf.org

--
To unsubscribe: mail -s unsubscribe axp-list-request@redhat.com < /dev/null

  reply	other threads:[~1996-09-04  8:26 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1996-09-04  3:20 I really don't know Brian Walters
1996-09-04  8:26 ` Fred Roy [this message]
  -- strict thread matches above, loose matches on Subject: below --
1996-09-04  3:56 David Mosberger
read-only archive

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox