[Bug 3102] Compilation error in sshbuf-misc.c on IRIX 6.5 with MIPSPro 7.4

bugzilla-daemon at bugzilla.mindrot.org bugzilla-daemon at bugzilla.mindrot.org
Mon Dec 9 12:55:14 AEDT 2019


https://bugzilla.mindrot.org/show_bug.cgi?id=3102

--- Comment #3 from Darren Tucker <dtucker at dtucker.net> ---
Created attachment 3342
  --> https://bugzilla.mindrot.org/attachment.cgi?id=3342&action=edit
check if memmem is declared and use for compat prototype

(In reply to Ole Weidner from comment #2)
> HAVE_MEMMEM is not defined in config.h and I couldn't find any
> traces of it in the IRIX system includes.

If you don't have HAVE_MEMMEM in config.h then I'm not sure what's
going on.  You could check config.log and look for the memmem test
output.

I did find one way to reproduce a similar error: where configure is
picking up a memmem from somewhere (maybe libc, or maybe one of the
other dependencies, I reproduced with gcc and a -lmemmem in LIBS) but
that will result in HAVE_MEMMEM in config.h.

The compat code only defines the prototype #ifndef HAVE_MEMMEM, thus in
this case nothing defines it so it defaults to int and you get the
mismatch.

The attached patch fixes what I found  (note that you will need to run
autoreconfig from autoconf 2.69 to rebuild configure before running
it).  It's worth trying for your case too.

The other potential gotcha: if you have a different config.h elsewhere
in your search path you might not be using the one you think you are.

-- 
You are receiving this mail because:
You are watching someone on the CC list of the bug.
You are watching the assignee of the bug.


More information about the openssh-bugs mailing list