On Sat, Jun 28, 2008 at 12:04:46PM +0000, Christian Weisgerber wrote: > Aaron Stellman <[EMAIL PROTECTED]> wrote: > > > xbatt started to segfault around month ago or so. Before that it was > > working properly on my ThinkPad T61. Last I checked i386 on the same > > hardware, it worked fine. here is the backtrace: > > That's a straightforward one. > > xbatt.c: In function `setColorSymbol': > xbatt.c:722: warning: cast to pointer from integer of different size > xbatt.c:731: warning: cast to pointer from integer of different size > xbatt.c:739: warning: cast to pointer from integer of different size > > If you check the lines, these warnings actually refer to malloc() > calls. malloc() is used without prototype, so the compiler thinks > it returns int, and truncates the return value correspondingly. > amd64 now can make use of more memory and malloc's default address > space has shifted beyond 4 GB, so truncating those pointers to 32 > bits will now actually hurt. > > I'll fix the port shortly. It works now; I appreciate the concrete explanation of the problem. Hopefully majority of such issues will be dug up by November. Thanks.
> > There are probably a number of other ports that suffer the same > problem. So far, malloc() pointer truncation bugs were only triggered > on alpha, and hardly any users test there. > > -- > Christian "naddy" Weisgerber [EMAIL PROTECTED] >
