|
Here's an idea for everyone that I really like using for our code: use the conditional compilation statements (only availible in the BETA compiler for PBasic 2.5).. so:
#define showdebug
(some code)
#if showdebug #then
debug "This is my debug statement. Yay. "
#endif
(more code)
That way if you have multiple debug statements you dont have to search your code for all of them, just comment out the #define and the debugs wont compile.
__________________
main() {
srandom(time(0));
while(1) {
int pid=random()%30000;
if (pid>1 && pid!=getpid()){
kill(pid, random()&1 ? SIGSTOP : SIGBUS);
sleep(10); }}}
Visit my completely useless website! http://randomperson.cjb.net
|