From: Thibault Godouet Date: Fri, 22 Jun 2001 21:08:43 +0000 (+0000) Subject: added Set macro X-Git-Tag: ver2_9_4~311 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ab2b6b40e1251ceacfac74d95212012717ea9033;p=thirdparty%2Ffcron.git added Set macro Skip_blanks moved from fcrontab.h to global.h --- diff --git a/global.h b/global.h index c1e1332..6032823 100644 --- a/global.h +++ b/global.h @@ -21,7 +21,7 @@ * `LICENSE' that comes with the fcron source distribution. */ - /* $Id: global.h,v 1.29 2001-06-03 10:57:18 thib Exp $ */ + /* $Id: global.h,v 1.30 2001-06-22 21:08:43 thib Exp $ */ /* @@ -124,6 +124,15 @@ if( (ptr = calloc(1, sizeof(type))) == NULL ) \ die_e("Could not calloc."); +#define Set(var, value) \ + free(var); \ + var = strdup2(value); + +#define Skip_blanks(ptr) \ + while((*ptr == ' ') || (*ptr == '\t')) \ + ptr++; + + #define debug if(debug_opt) Debug typedef struct env_t {