This is the mail archive of the
fortran@gcc.gnu.org
mailing list for the GNU Fortran project.
Re: Segmentation fault calling fortran function from c
- From: FX Coudert <fxcoudert at gmail dot com>
- To: asilter79 <asilter79 at hotmail dot com>
- Cc: fortran at gcc dot gnu dot org
- Date: Wed, 4 Jul 2007 16:40:42 +0200
- Subject: Re: Segmentation fault calling fortran function from c
- Dkim-signature: a=rsa-sha1; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:in-reply-to:references:mime-version:content-type:message-id:cc:content-transfer-encoding:from:subject:date:to:x-mailer; b=aFbr068iQqimNhMGchXc3Xlafn7NbBzsb3GwFowBfk6VQ4/Qg+8a9a20Vy69xaOzc4z0m+FV86BkeiZvypOo8G5Evv3xKmkY2voGxeZpaPUaxm4C7T+da922Jyzsf+dlvdLA1LIZ0jW70EWZWNs523npJ6Xb8S/yOpjvU5jtwns=
- Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:in-reply-to:references:mime-version:content-type:message-id:cc:content-transfer-encoding:from:subject:date:to:x-mailer; b=WbB4SFxMUIAwQUqyrxQrlnTTfaI8rRPNS2+BuNRPtOoeYQgRlskEw1BKrEXoV6W5vgiani6e5iX0rZFS9zAHyJduk5L85jRxZyBHiLaGs81zZM76PU2hUsFX43e6DtG4gPt1OWvDlKWep06s1sofrnYZxh7boxRK+c5pHHky4hc=
- References: <11431780.post@talk.nabble.com>
b = intgerigonder_(a);
Fortran passes variables by reference, thus you need to change that
line into "b = intgerigonder_(&a);"
FX