Date: Thu, 9 Dec 2010 16:10:16 GMT From: Chris Calvey <chris@geonumerical.org> To: freebsd-ports-bugs@FreeBSD.org Subject: Re: ports/152304: sysutils/fcron: illegal instruction 4 Message-ID: <201012091610.oB9GAGYO072420@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
The following reply was made to PR ports/152304; it has been noted by GNATS. From: Chris Calvey <chris@geonumerical.org> To: bug-followup@FreeBSD.org Cc: Subject: Re: ports/152304: sysutils/fcron: illegal instruction 4 Date: Thu, 9 Dec 2010 15:39:16 +0000 I have found the cause of this bug. When subs.c is compiled the following warning message is generated: subs.c: In function 'open_as_user': subs.c:124: warning: 'mode_t' is promoted to 'int' when passed through '...' subs.c:124: warning: (so you should pass 'int' not 'mode_t' to 'va_arg') subs.c:124: note: if this code is reached, the program will abort gcc generates a ud2a instruction in the resulting subs.o object file and the program indeed aborts when it hits this instruction. This is a temporary patch that resolves this problem: --- subs.c.orig 2010-12-09 14:41:13.000000000 +0000 +++ subs.c 2010-12-09 14:41:46.000000000 +0000 @@ -121,7 +121,7 @@ if (flags & O_CREAT) { va_start(ap, flags); - mode = va_arg(ap, mode_t); + mode = va_arg(ap, int); va_end(ap); } @@ -179,7 +179,7 @@ if (flags & O_CREAT) { va_start(ap, flags); - mode = va_arg(ap, mode_t); + mode = va_arg(ap, int); va_end(ap); } I have reported the above to the fcron developer in addition. Regards Chris
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201012091610.oB9GAGYO072420>