tac0S
Template Affectional Command Operating System
Functions
utility.cc File Reference

Debugging routines. More...

#include "copyright.h"
#include "utility.h"
#include "/usr/include/stdarg.h"

Functions

void DebugInit (const char *flagList)
 DebugInit Initialize so that only DEBUG messages with a flag in flagList will be printed. More...
 
bool DebugIsEnabled (char flag)
 DebugIsEnabled. More...
 
void DEBUG (char flag, const char *format,...)
 DEBUG Print a debug message, if flag is enabled. Like printf, only with an extra argument on the front. More...
 

Detailed Description

Debugging routines.

Author
Olivier Hureau, Hugo Feydel , Julien ALaimo
 Debugging routines.  Allows users to control whether to 
 print DEBUG statements, based on a command line argument.

Copyright (c) 1992-1993 The Regents of the University of California. All rights reserved. See copyright.h for copyright notice and limitation of liability and disclaimer of warranty provisions.

Function Documentation

void DEBUG ( char  flag,
const char *  format,
  ... 
)

DEBUG Print a debug message, if flag is enabled. Like printf, only with an extra argument on the front.

Print debug message.

void DebugInit ( const char *  flagList)

DebugInit Initialize so that only DEBUG messages with a flag in flagList will be printed.

Include interface that isolates us from the host machine system library. Requires definition of bool, and VoidFunctionPtr.

If the flag is "+", we enable all DEBUG messages.

Parameters
[in]
bool DebugIsEnabled ( char  flag)

DebugIsEnabled.

Is this debug flag enabled?

Returns
TRUE if DEBUG messages with "flag" are to be printed.