From owner-freebsd-hackers@FreeBSD.ORG Mon Jun 20 10:34:12 2005 Return-Path: X-Original-To: hackers@freebsd.org Delivered-To: freebsd-hackers@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 2834516A41C for ; Mon, 20 Jun 2005 10:34:12 +0000 (GMT) (envelope-from cole@opteqint.net) Received: from kalypso.opteqint.net (kalypso.opteqint.net [160.124.112.28]) by mx1.FreeBSD.org (Postfix) with ESMTP id A3AAB43D48 for ; Mon, 20 Jun 2005 10:34:11 +0000 (GMT) (envelope-from cole@opteqint.net) Received: from 196-47-3-224.access.uunet.co.za ([196.47.3.224] helo=deadmind) by kalypso.opteqint.net with esmtpsa (TLSv1:RC4-MD5:128) (Exim 4.43 (FreeBSD)) id 1DkJbN-000NH6-2k for hackers@freebsd.org; Mon, 20 Jun 2005 12:34:10 +0200 Message-ID: <000b01c57583$fa036820$4206000a@deadmind> From: "Cole" To: Date: Mon, 20 Jun 2005 12:36:33 +0200 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 5.50.4922.1500 X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4939.300 X-Spam-Score: -100.0 (---------------------------------------------------) X-Spam-Report: Spam detection software, running on the system "kalypso.opteqint.net", has identified this incoming email as possible spam. The original message has been attached to this so you can view it (if it isn't spam) or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: Hi Ive been looking at nbtscan, the 1.5.1 version, and it seems to core, with a segmentation fault. I traced the problem down to a FD_ZERO(fdsr). I was wondering is there any like checking that can be done before issuing that command. Its part of a while loop, inside the program, where it runs fine, till the last loop, im guessing maybe its maybe doing an extra loop where it shouldnt, but the while loop is while( (select(sock+1, fdsr, fdsw, NULL, &select_timeout) ) > 0 ) { [...] Content analysis details: (-100.0 points, 4.2 required) pts rule name description ---- ---------------------- -------------------------------------------------- -100 USER_IN_WHITELIST From: address is in the user's white-list Cc: Subject: FD_ZERO problem X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Cole List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 20 Jun 2005 10:34:12 -0000 Hi Ive been looking at nbtscan, the 1.5.1 version, and it seems to core, with a segmentation fault. I traced the problem down to a FD_ZERO(fdsr). I was wondering is there any like checking that can be done before issuing that command. Its part of a while loop, inside the program, where it runs fine, till the last loop, im guessing maybe its maybe doing an extra loop where it shouldnt, but the while loop is while( (select(sock+1, fdsr, fdsw, NULL, &select_timeout) ) > 0 ) { So I dont think the while is giving a false positive, but this isnt my code, I havent had time to check it all out, but I was just wondering if there are any checks that can be done to the fd_set * fdsr pointer before issuing a FD_ZERO? Regards /Cole