Thread View: gnu.gdb.bug
1 messages
1 total messages
Started by Paul Hudson
Tue, 18 Apr 1989 08:32
bug with void pointer subtraction.
Author: Paul Hudson
Date: Tue, 18 Apr 1989 08:32
Date: Tue, 18 Apr 1989 08:32
16 lines
882 bytes
882 bytes
The line print (void*)1 - (void*)0 causes gdb3.1 (sun3,os4) to give an arithmetic exception. Presumably it's trying to divide the difference by the size of the thing pointed to, which is zero (although gcc thinks it's one, sometimes ;-). Paul Hudson Snail mail: Monotype ADG Email: ...!ukc!acorn!moncam!paul Science Park, paul@moncam.co.uk Milton Road, "Sun Microsysytems: Cambridge, The Company is Arrogant (TM)" CB4 4FQ
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads