/[monit]/monit/p.y
ViewVC logotype

Diff of /monit/p.y

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.45 by rory, Sat Dec 7 08:35:24 2002 UTC revision 1.46 by hauk, Tue Dec 17 19:55:17 2002 UTC
# Line 325  ssl             : ssldisable { Run.httpd Line 325  ssl             : ssldisable { Run.httpd
325                  | sslenable pemfile clientpemfile allowselfcert {                  | sslenable pemfile clientpemfile allowselfcert {
326                    Run.httpdssl= TRUE;                                      Run.httpdssl= TRUE;                  
327                    if(!have_ssl()) {                    if(!have_ssl()) {
328                       error("%s: SSL is not supported at line %d\n",                      log("%s: SSL is not supported at line %d\n",
329                             prog, lineno-1);                          prog, lineno-1);
330                       cfg_errflag++;                       cfg_errflag++;
331                     }                     }
332                   }                   }
# Line 380  allow           : ALLOW STRING':'STRING Line 380  allow           : ALLOW STRING':'STRING
380                   }                   }
381                  | ALLOW STRING {                  | ALLOW STRING {
382                     if(!add_host_allow($2)) {                     if(!add_host_allow($2)) {
383                       error("%s: Hostname '%s' did not resolve at line %d\n",                       log("%s: Hostname '%s' did not resolve at line %d\n",
384                             prog, $2, lineno-1);                           prog, $2, lineno-1);
385                       cfg_errflag++;                       cfg_errflag++;
386                     }                     }
387                     free($2);                     free($2);
# Line 617  void yyerror(const char *msg) { Line 617  void yyerror(const char *msg) {
617    
618    ASSERT(msg);    ASSERT(msg);
619    
620    error("%s: %s '%s' at line %d\n", prog, msg, yytext, lineno );    log("%s: %s '%s' at line %d\n", prog, msg, yytext, lineno );
621    cfg_errflag++;    cfg_errflag++;
622    
623  }  }
# Line 641  int parse(char *controlfile) { Line 641  int parse(char *controlfile) {
641        
642    if ((yyin = fopen(controlfile,"r")) == (FILE *)NULL) {    if ((yyin = fopen(controlfile,"r")) == (FILE *)NULL) {
643            
644      error("%s: Error opening the control file '%s' -- %s\n",      log("%s: Error opening the control file '%s' -- %s\n",
645            prog, controlfile, STRERROR);          prog, controlfile, STRERROR);
646      return(FALSE);      return(FALSE);
647            
648    }    }
# Line 793  static void addchecksum(char *filename, Line 793  static void addchecksum(char *filename,
793            
794    } else if ( ! set_md5sum(&c->md5, filename) ) {    } else if ( ! set_md5sum(&c->md5, filename) ) {
795            
796      error("%s: Cannot compute a checksum for %s at line %d\n",      log("%s: Cannot compute a checksum for %s at line %d\n",
797            prog, filename, lineno-1);          prog, filename, lineno-1);
798      cfg_errflag++;      cfg_errflag++;
799    
800    }    }
# Line 898  static void addport(struct PortSet *pp) Line 898  static void addport(struct PortSet *pp)
898    
899      if ( !have_ssl() ) {      if ( !have_ssl() ) {
900    
901        error("%s: The ssl check cannot be activated at line %d, "        log("%s: The ssl check cannot be activated at line %d, "
902              "SSL is not support.\n",            "SSL is not support.\n",
903              prog,lineno-1);            prog,lineno-1);
904        cfg_errflag++;        cfg_errflag++;
905    
906      } else {      } else {
# Line 936  static void addresource(struct ResourceS Line 936  static void addresource(struct ResourceS
936    
937    if ( ! Run.doprocess ) {    if ( ! Run.doprocess ) {
938    
939      error("%s: Cannot activate process check at line %d\n"      log("%s: Cannot activate process check at line %d\n"
940            "\t(The process status engine was disabled. On certain"          "\t(The process status engine was disabled. On certain"
941            " systems you must\n\trun monit as root to utilize this"          " systems you must\n\trun monit as root to utilize this"
942            " feature)\n", prog, lineno-1);          " feature)\n", prog, lineno-1);
943      cfg_errflag++;      cfg_errflag++;
944            
945    }    }
# Line 954  static void addresource(struct ResourceS Line 954  static void addresource(struct ResourceS
954    
955    if ( r->max_cycle < 1 ) {    if ( r->max_cycle < 1 ) {
956    
957      error("%s: The number of cycles must be greater then 0 in line %d\n",      log("%s: The number of cycles must be greater then 0 in line %d\n",
958            prog, lineno-1);          prog, lineno-1);
959      cfg_errflag++;      cfg_errflag++;
960            
961    }    }
# Line 1057  static void addargument(char *argument) Line 1057  static void addargument(char *argument)
1057        
1058    if(command->length >= ARGMAX) {    if(command->length >= ARGMAX) {
1059            
1060      error("%s: Exceeded maximum number of program arguments at line %d\n",      log("%s: Exceeded maximum number of program arguments at line %d\n",
1061            prog, lineno-1);          prog, lineno-1);
1062      cfg_errflag++;      cfg_errflag++;
1063            
1064    }    }
# Line 1255  static void check_name(char *name) { Line 1255  static void check_name(char *name) {
1255    
1256    if ( exist_process(name) ) {    if ( exist_process(name) ) {
1257            
1258      error("%s: Name conflict at line %d - check name '%s' already defined\n",      log("%s: Name conflict at line %d - check name '%s' already defined\n",
1259            prog, lineno, name);          prog, lineno, name);
1260            
1261      cfg_errflag++;      cfg_errflag++;
1262            

Legend:
Removed from v.1.45  
changed lines
  Added in v.1.46

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26