From: Arthur Bergman Subject: debugging frustration Date: Mon, 14 Feb 2005 14:20:49 +0000 Message-ID: <6964b3969b0cbc632c2161cb16ad0e8b@fotango.com> Mime-Version: 1.0 (Apple Message framework v619.2) Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit Sender: xen-devel-admin@lists.sourceforge.net Errors-To: xen-devel-admin@lists.sourceforge.net List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , List-Archive: To: xen-devel@lists.sourceforge.net List-Id: xen-devel@lists.xenproject.org In an effort to hide debugging messages, I noticed that xfrd.c undefs DEBUG after setting it to DEBUG 1. Unless there is something really fundamental about the gcc c preprocessor I don't know about, this doesn't seem very helpful. Below is a patch that lets the outside user set debugging instead of hardcoding it. Also, is there a reason that not having DEBUG in turns dprintf into do {} while(0) instead of just turning into "" Cheers Arthur ----- CTO @ Fotango Ltd +447834716919 http://www.fotango.com/ --- xfrd.c.old 2005-02-14 14:17:49.000000000 +0000 +++ xfrd.c 2005-02-14 14:17:58.000000000 +0000 @@ -49,8 +49,6 @@ #include "select.h" #define MODULE_NAME "XFRD" -#define DEBUG 1 -#undef DEBUG #include "debug.h" /* ------------------------------------------------------- SF email is sponsored by - The IT Product Guide Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now. http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click