bugGNU gv - Bugs: bug #24380, gv 3.6.6 on Mac OS X: Undefined...

 
 

You are not allowed to post comments on this tracker with your current authentication level.

bug #24380: gv 3.6.6 on Mac OS X: Undefined symbols: _strndup

Submitter:  Ryan Carsten Schmidt <ryandesign>
Submitted:  Fri 26 Sep 2008 07:39:45 AM UTC
   
 
Category:  Sources configuration Severity:  3 - Normal
Item Group:  None Status:  Fixed
Privacy:  Public Assigned to:  msteinbo
Open/Closed:  Closed Release:  3.6.6

Jump to the original submission

Sun 22 Mar 2009 09:27:40 AM UTC, comment #9: 

GNU gv 3.6.7 has been released. It contains the bug fix, so I can close this bug.

Markus Steinborn <msteinbo>
Group administrator
Fri 20 Mar 2009 08:35:38 AM UTC, comment #8: 

That's great. Thanks.

Vaclav Stepan <vaclav_stepan>
Thu 19 Mar 2009 06:59:23 AM UTC, comment #7: 

GNU gv 3.6.7 will be released this weekend.

Markus Steinborn <msteinbo>
Group administrator
Wed 18 Mar 2009 05:40:31 PM UTC, comment #6: 

Can a release be made to correct this?

It is a problem also on Solaris systems as their libc does not implement strndup.

Vaclav Stepan <vaclav_stepan>
Sun 28 Sep 2008 06:29:54 AM UTC, comment #5: 

Fixed in CVS by providing an strndup implementation called GNU_strndup und using it instead of strndup.

Markus Steinborn <msteinbo>
Group administrator
Sat 27 Sep 2008 05:35:53 AM UTC, comment #4: 

Thanks. The next release will contain the fix as announced.

Markus Steinborn <msteinbo>
Group administrator
Sat 27 Sep 2008 12:17:22 AM UTC, comment #3: 

Yes, that does compile now, thanks!

Ryan Carsten Schmidt <ryandesign>
Fri 26 Sep 2008 03:37:51 PM UTC, comment #2: 

Could you please add the following code at the beginning of src/secsscanf.c just after the includes and report me if it helps? If so, I will modify the configure script to conditionally insert this code if needed.

/* begin test code */
size_t strnlen(const char *s, size_t len)
{
    size_t i;
    for(i=0; i<len && *(s+i); i++);
    return i;
}

char* strndup (char const *s, size_t n)
{
  size_t len = strnlen (s, n);
  char *new = malloc (len + 1);

  if (new == NULL)
    return NULL;

  new[len] = '\0';
  return memcpy (new, s, len);
}
/* end test code */

Markus Steinborn <msteinbo>
Group administrator
Fri 26 Sep 2008 01:49:45 PM UTC, comment #1: 

Thanks for the bug report. Obviously the patch from "2008-09-09  Olaf Kirch <okir@suse.de>" introduces the usage of "strndup". The purpose is to make calls to sscanf overflow free.

I'll check what can be done soon.

Markus Steinborn <msteinbo>
Group administrator
Fri 26 Sep 2008 07:39:45 AM UTC, original submission:  

Trying to compile gv 3.6.6 on Mac OS X 10.4.11 Intel with Xcode 2.5 I get this:

/usr/libexec/gcc/i686-apple-darwin8/4.0.1/ld: Undefined symbols:
_strndup

3.6.5 did not have this problem.

My understanding based on some brief Google research is that strndup does not exist on Mac OS X.

http://www.google.com/search?q=strndup+mac


Ryan Carsten Schmidt <ryandesign>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by vaclav_stepan (Posted a comment)
  • -email is unavailable- added by msteinbo (Posted a comment)
  • -email is unavailable- added by ryandesign (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

     

    Follow 7 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2009-03-22 msteinbo StatusWorkaround available Fixed
        Open/ClosedOpen Closed
    2008-09-27 msteinbo StatusNeed Info Workaround available
    2008-09-26 msteinbo StatusIn Progress Need Info
    2008-09-26 msteinbo StatusNone In Progress
        Assigned toNone msteinbo
        ReleaseNone 3.6.6

    Back to the top

    Powered by Savane 3.13-3230.
    Corresponding source code