]> git.proxmox.com Git - mirror_smartmontools-debian.git/blobdiff - os_generic.cpp
Updated changelog
[mirror_smartmontools-debian.git] / os_generic.cpp
index d57e17f81962ed3b1c9505db72add3ca7346d39e..e4b79995fba5d57f6c257cdf7ca2be6751615a09 100644 (file)
@@ -82,7 +82,7 @@
 // should have one *_H_CVSID macro appearing below for each file
 // appearing with #include "*.h" above.  Please list these (below) in
 // alphabetic/dictionary order.
-const char *os_XXXX_c_cvsid="$Id: os_generic.cpp,v 1.28 2009/01/20 00:31:17 dlukes Exp $" \
+const char *os_XXXX_c_cvsid="$Id: os_generic.cpp 3191 2010-10-27 19:55:33Z chrfranke $" \
 ATACMDS_H_CVSID CONFIG_H_CVSID OS_GENERIC_H_CVSID UTILITY_H_CVSID;
 
 // This is here to prevent compiler warnings for unused arguments of
@@ -106,8 +106,6 @@ static void unsupported(){
 
   if (!warninggiven) {
     char *osname;
-    extern unsigned char debugmode;
-    unsigned char savedebugmode=debugmode;
     
 #ifdef HAVE_UNAME
     struct utsname ostype;
@@ -117,14 +115,12 @@ static void unsupported(){
     osname="host's";
 #endif
 
-    debugmode=1;
     pout("\n"
          "############################################################################\n"
          "WARNING: smartmontools has not been ported to the %s Operating System.\n"
          "Please see the files os_generic.cpp and os_generic.h for porting instructions.\n"
          "############################################################################\n\n",
          osname);
-    debugmode=savedebugmode;
     warninggiven=1;
   }
   
@@ -175,7 +171,7 @@ public:
   virtual const char * get_os_version_str();
 #endif
 
-  virtual const char * get_app_examples(const char * appname);
+  virtual std::string get_app_examples(const char * appname);
 
   virtual bool scan_smart_devices(smart_device_list & devlist, const char * type,
     const char * pattern = 0);
@@ -189,7 +185,7 @@ protected:
 
   virtual smart_device * get_custom_smart_device(const char * name, const char * type);
 
-  virtual const char * get_valid_custom_dev_types_str();
+  virtual std::string get_valid_custom_dev_types_str();
 };
 
 
@@ -203,11 +199,11 @@ const char * generic_smart_interface::get_os_version_str()
 }
 #endif
 
-const char * generic_smart_interface::get_app_examples(const char * appname)
+std::string generic_smart_interface::get_app_examples(const char * appname)
 {
   if (!strcmp(appname, "smartctl"))
     ::print_smartctl_examples(); // this prints to stdout ...
-  return 0; // ... so don't print again.
+  return ""; // ... so don't print again.
 }
 
 // Return ATA device object for the given device name or NULL
@@ -267,7 +263,7 @@ smart_device * generic_smart_interface::get_custom_smart_device(const char * nam
   return NULL;
 }
 
-const char * generic_smart_interface::get_valid_custom_dev_types_str()
+std::string generic_smart_interface::get_valid_custom_dev_types_str()
 {
   return "";
 }