Opened 15 years ago

Closed 15 years ago

#193 closed defect (fixed)

TCP crashes in pq_find()

Reported by: Jakub Jermář Owned by:
Priority: major Milestone: 0.4.2
Component: helenos/net/tcp Version: mainline
Keywords: Cc:
Blocker for: Depends on:
See also:

Description

This is an example of one problem currently found in the TCP server:

Running the echo server on a TCP port 8080 and connecting to it using telnet 8080 from the host system, the TCP server dies after it receives data ("ping").

See the attachments for the output of the echo server and also the stacktrace of the TCP crash.

Attachments (3)

Screenshot-QEMU.png (33.5 KB ) - added by Jakub Jermář 15 years ago.
Screenshot with the stack trace.
Screenshot-QEMU-1.png (29.3 KB ) - added by Jakub Jermář 15 years ago.
Screenshot with the echo server output.
tcp.disasm.bz2 (196.3 KB ) - added by Jakub Jermář 15 years ago.
TCP server disassembled

Download all attachments as: .zip

Change History (6)

by Jakub Jermář, 15 years ago

Attachment: Screenshot-QEMU.png added

Screenshot with the stack trace.

by Jakub Jermář, 15 years ago

Attachment: Screenshot-QEMU-1.png added

Screenshot with the echo server output.

by Jakub Jermář, 15 years ago

Attachment: tcp.disasm.bz2 added

TCP server disassembled

comment:1 by Jakub Jermář, 15 years ago

Excerpt from uspace/srv/net/structures/packet/packet.c, pq_find():

@@ -225,6 +225,8 @@
 	item = pm_find( packet->next );
 	while( item && ( item != packet )){
 		item = pm_find( item->next );
 		if( item->order == order ){
 			return item;
 		}

Looks like the second pm_find()'s return value is not checked for NULL.

comment:2 by Jakub Jermář, 15 years ago

Milestone: 0.5.00.4.2
Summary: TCP needs more workTCP crashes in pq_find()

comment:3 by Jakub Jermář, 15 years ago

Resolution: fixed
Status: newclosed

Fixed in changeset:head,312.

Note: See TracTickets for help on using tickets.