From: SourceForge.net <no...@so...> - 2007-01-27 22:19:01
|
Bugs item #1630918, was opened at 2007-01-08 22:23 Message generated for change (Comment added) made by elfring You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=111118&aid=1630918&group_id=11118 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: other Group: version 3.4 Status: Open Resolution: None Priority: 5 Private: No Submitted By: Markus Elfring (elfring) Assigned to: Fabian Keil (fabiankeil) Summary: Check return codes everywhere Initial Comment: Some checks for return codes are missing. Example: Would you like to add more error handling for return values from "pthread_mutex_lock" in the functions like "accept_connection" and "resolve_hostname_to_ip". http://ijbswa.cvs.sourceforge.net/ijbswa/current/jbsockets.c?revision=1.41&view=markup ---------------------------------------------------------------------- >Comment By: Markus Elfring (elfring) Date: 2007-01-27 23:19 Message: Logged In: YES user_id=572001 Originator: YES The corresponding checking for error codes is required for all operating systems where the Pthread API is supported. ---------------------------------------------------------------------- Comment By: Fabian Keil (fabiankeil) Date: 2007-01-27 12:38 Message: Logged In: YES user_id=875547 Originator: NO I repeat my question: In what situation and one which operating system do you think that's necessary for the way pthread_mutex_lock() is used in Privoxy? Note that Privoxy doesn't use recursive locks and mutexes are initializes on startup. ---------------------------------------------------------------------- Comment By: Markus Elfring (elfring) Date: 2007-01-26 22:32 Message: Logged In: YES user_id=572001 Originator: YES All return values should be checked to detect if something went wrong. The consequence of a failed lock is that the process became thread-unsafe. The program can not safely continue to run as usual. The function "abort()" should be called. http://groups.google.com/group/comp.programming.threads/browse_frm/thread/bd013d03610120d2/9989672acf27e396 ---------------------------------------------------------------------- Comment By: Fabian Keil (fabiankeil) Date: 2007-01-26 17:53 Message: Logged In: YES user_id=875547 Originator: NO In what situation and one which operating system do you think that's necessary for the way pthread_mutex_lock() is used in Privoxy? And what do you think Privoxy should do in case of a failed lock? ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=111118&aid=1630918&group_id=11118 |