Gentoo Archives: gentoo-embedded

From: Natanael Copa <mlists@××××××.org>
To: gentoo-embedded@l.g.o
Subject: Re: [gentoo-embedded] uclibc "emerge sync" segfaults
Date: Mon, 02 Aug 2004 12:43:29
Message-Id: 410E36E7.7030203@tanael.org
In Reply to: Re: [gentoo-embedded] uclibc "emerge sync" segfaults by Mike Frysinger
1 Mike Frysinger wrote:
2
3 >On Monday 02 August 2004 04:32 am, Natanael Copa wrote:
4 >
5 >
6 >>I just came back from a longweekend and wanted to check out what was new.
7 >>
8 >>But emerge sync segfaulted.
9 >><snip>
10 >>I guess there is a bug in libresolv in uclibc
11 >>
12 >>
13 >
14 >yeah, we've been looking into this ...
15 >i dont know if solar found anything over the weekend (i was gone), but find
16 >attached a small .c file i made to reproduce the error
17 >
18 >
19
20 Thanks!
21
22 The problem is that h->h_aliases is pointing at an unreadable nun-null
23 location.
24
25 I ran the code through gdb and it is strnlen that fails.
26
27 I added those lines:
28
29 char *p = h->h_aliases[hidx];
30 printf("Address of list is: %x\n", p);
31 printf("Value of h->h_aliases[hidx] is: %i", (int)*p);
32
33 it segfaults when reading *p.
34
35 I also tried the code in my uclib environment based on ucrux and exactly
36 the same thing happened there. So its definitively an uclibc bug.
37
38 --
39 Natanael Copa
40
41
42 --
43 gentoo-embedded@g.o mailing list

Replies

Subject Author
Re: [gentoo-embedded] uclibc "emerge sync" segfaults Mike Frysinger <vapier@g.o>