Code

Added argc checks before attempting to access argv[]
[nagiosplug.git] / plugins / check_nt.c
index 4d57077cd4e56c7109297bd69f12e8d7e98daf21..65c4e693adb4945cd0da4d6da15b963351fc32da 100644 (file)
@@ -7,6 +7,8 @@
  * Copyright (c) 2000-2002 Yves Rubin (rubiyz@yahoo.com)
  *
  * Description:
+ * 
+ * This requires NSClient software to run on NT (http://nsclient.ready2run.nl/)
  *
  * License Information:
  *
@@ -480,7 +482,7 @@ int process_arguments(int argc, char **argv){
                                        return ERROR;
                                break;
                        case 'l': /* value list */
-                               asprintf(&value_list,optarg);
+                               asprintf(&value_list,"%s",optarg);
                                check_value_list=TRUE;
                                break;
                        case 'w': /* warning threshold */