module/idoutils/include/utils.h

Go to the documentation of this file.
00001 /************************************************************************
00002  *
00003  * UTILS.H - IDO utilities header file
00004  * Copyright (c) 2005-2008 Ethan Galstad
00005  * Copyright (c) 2009-2011 Icinga Development Team (http://www.icinga.org)
00006  *
00007  ************************************************************************/
00008 
00009 #ifndef _IDO_UTILS_H
00010 #define _IDO_UTILS_H
00011 
00012 /* my_free has been freed from bondage as a function */
00013 #define my_free(ptr) do { if(ptr) { free(ptr); ptr = NULL; } } while(0)
00014 
00015 typedef struct ido_dbuf_struct{
00016         char *buf;
00017         unsigned long used_size;
00018         unsigned long allocated_size;
00019         unsigned long chunk_size;
00020         }ido_dbuf;
00021 
00022 
00023 int ido_dbuf_init(ido_dbuf *,int);
00024 int ido_dbuf_free(ido_dbuf *);
00025 int ido_dbuf_strcat(ido_dbuf *,char *);
00026 
00027 int my_rename(char *,char *);
00028 
00029 void idomod_strip(char *);
00030 
00031 #endif

Generated on Wed Mar 30 17:22:22 2011 for icinga-core by  doxygen 1.4.7