Return-Path: Subject: RE: [Bluez-devel] textfile.c find_key From: Marcel Holtmann To: bluez-devel@lists.sourceforge.net In-Reply-To: References: Content-Type: text/plain Message-Id: <1131479720.5544.6.camel@blade> Mime-Version: 1.0 Sender: bluez-devel-admin@lists.sourceforge.net Errors-To: bluez-devel-admin@lists.sourceforge.net Reply-To: bluez-devel@lists.sourceforge.net List-Unsubscribe: , List-Id: BlueZ development List-Post: List-Help: List-Subscribe: , List-Archive: Date: Tue, 08 Nov 2005 20:55:20 +0100 Hi Robert, > Not sure if you are interested in this but in the file textfile.c, > function find_key. If map is ever NULL the strstr will segment fault. > An instance of this happening would be when the key file was empty. > This might happen if a Linux Op was removing keys that were > invalidated by a lost pairing. I feel that in general checking for a > NULL is better than not. how can map be NULL? Check "man mmap" about the return value of mmap(). Regards Marcel ------------------------------------------------------- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42" plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php _______________________________________________ Bluez-devel mailing list Bluez-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/bluez-devel