dnxError.c File Reference

#include "dnxError.h"
#include <errno.h>
#include <string.h>

Go to the source code of this file.

Defines

#define elemcount(x)   (sizeof(x)/sizeof(*(x)))

Functions

dnxError dnxGetLastError (void)
 Return the last error code stored in the global dnx error variable.
void dnxSetLastError (dnxError eno)
 Set the global dnx error variable to some dnx error value.
char * dnxErrorString (dnxError eno)
 Return an error string that matches a specified dnx error code.

Variables

static dnxError gLastError = DNX_OK


Define Documentation

#define elemcount (  )     (sizeof(x)/sizeof(*(x)))

Definition at line 37 of file dnxError.c.


Function Documentation

char* dnxErrorString ( dnxError  eno  ) 

Return an error string that matches a specified dnx error code.

Parameters:
[in] eno - the error code for which a string representation is desired.
Returns:
A pointer to a statically allocated string representation of the error code specified in errno.

Definition at line 55 of file dnxError.c.

Referenced by dnxAgentServer(), dnxCfgParserParse(), dnxCollector(), dnxCollectorCreate(), dnxDispatcherCreate(), dnxGetNodeRequest(), dnxInitAgent(), dnxPluginInit(), dnxReconfigure(), dnxRegisterNode(), dnxRegistrar(), dnxRegistrarCreate(), dnxSendJobMsg(), dnxServerInit(), dnxTimer(), dnxTimerCreate(), dnxWlmCreate(), dnxWorker(), ehSvcCheck(), initClientComm(), initWorkerComm(), main(), nebmodule_init(), processCommands(), ProcessJobTransferMsg(), and workerCreate().

dnxError dnxGetLastError ( void   ) 

Return the last error code stored in the global dnx error variable.

Todo:
Create a mechanism for preserving error stack details.

Definition at line 47 of file dnxError.c.

void dnxSetLastError ( dnxError  eno  ) 

Set the global dnx error variable to some dnx error value.

Parameters:
[in] eno - the value to be set.

Definition at line 51 of file dnxError.c.


Variable Documentation

dnxError gLastError = DNX_OK [static]

Last known error code.

Definition at line 39 of file dnxError.c.

Referenced by dnxGetLastError(), and dnxSetLastError().


Generated on Tue Apr 13 15:15:29 2010 for DNX by  doxygen 1.5.6