diff --git a/include/History.h b/include/History.h index c00a13daef..c6bf8da437 100644 --- a/include/History.h +++ b/include/History.h @@ -217,4 +217,5 @@ private: static int dump(ostringstream& oss, int num, char **names, char **values); }; -#endif /*HISTORY_H_*/ \ No newline at end of file +#endif /*HISTORY_H_*/ + diff --git a/include/MySqlDB.h b/include/MySqlDB.h index 71d9097345..94ff2055ab 100644 --- a/include/MySqlDB.h +++ b/include/MySqlDB.h @@ -126,4 +126,5 @@ public: }; #endif -#endif /*MYSQL_DB_H_*/ \ No newline at end of file +#endif /*MYSQL_DB_H_*/ + diff --git a/include/ObjectSQL.h b/include/ObjectSQL.h index 4d64480c80..2043260f68 100644 --- a/include/ObjectSQL.h +++ b/include/ObjectSQL.h @@ -69,4 +69,5 @@ protected: SqlDB * db) = 0; }; -#endif /*OBJECT_SQL_H_*/ \ No newline at end of file +#endif /*OBJECT_SQL_H_*/ + diff --git a/include/RangedLeases.h b/include/RangedLeases.h index a97de82627..7f4af957a6 100644 --- a/include/RangedLeases.h +++ b/include/RangedLeases.h @@ -106,4 +106,5 @@ private: }; -#endif /*RANGED_LEASES_H_*/ \ No newline at end of file +#endif /*RANGED_LEASES_H_*/ + diff --git a/include/UserPool.h b/include/UserPool.h index fd8225e6bb..3c96cdf683 100644 --- a/include/UserPool.h +++ b/include/UserPool.h @@ -187,4 +187,5 @@ private: int init_cb(void *nil, int num, char **values, char **names); }; -#endif /*USER_POOL_H_*/ \ No newline at end of file +#endif /*USER_POOL_H_*/ + diff --git a/include/VirtualNetwork.h b/include/VirtualNetwork.h index 3d96187e30..33172da74e 100644 --- a/include/VirtualNetwork.h +++ b/include/VirtualNetwork.h @@ -51,7 +51,7 @@ public: { UNINITIALIZED = -1, RANGED = 0, - FIXED = 1, + FIXED = 1 }; // ************************************************************************* diff --git a/include/mem_collector.h b/include/mem_collector.h index 318625fa8b..95ef4bce95 100644 --- a/include/mem_collector.h +++ b/include/mem_collector.h @@ -51,4 +51,5 @@ void mem_collector_cleanup(mem_collector * mc); */ char * mem_collector_strdup(mem_collector *mc, const char * str); -#endif /*MEM_COLLECTOR_H_*/ \ No newline at end of file +#endif /*MEM_COLLECTOR_H_*/ + diff --git a/src/authm/AuthManager.cc b/src/authm/AuthManager.cc index d3ccf6a6d4..bf3b71f917 100644 --- a/src/authm/AuthManager.cc +++ b/src/authm/AuthManager.cc @@ -181,7 +181,7 @@ void AuthRequest::add_auth(Object ob, self_authorize = self_authorize && auth; auths.push_back(oss.str()); -}; +} /* -------------------------------------------------------------------------- */ /* -------------------------------------------------------------------------- */ @@ -228,7 +228,7 @@ int AuthManager::start() rc = pthread_create(&authm_thread,&pattr,authm_action_loop,(void *) this); return rc; -}; +} /* -------------------------------------------------------------------------- */ /* -------------------------------------------------------------------------- */ diff --git a/src/common/Attribute.cc b/src/common/Attribute.cc index 25dcd94eed..05f7279dd8 100644 --- a/src/common/Attribute.cc +++ b/src/common/Attribute.cc @@ -180,4 +180,5 @@ string VectorAttribute::vector_value(const char *name) const { return it->second; } -}; +} + diff --git a/src/common/test/mem_collector.cc b/src/common/test/mem_collector.cc index 2a54e0bc9a..19397c2031 100644 --- a/src/common/test/mem_collector.cc +++ b/src/common/test/mem_collector.cc @@ -55,6 +55,12 @@ public: CPPUNIT_ASSERT(strcmp(mc.str_buffer[1],"ADIOS")==0); CPPUNIT_ASSERT(strcmp(mc.str_buffer[2],"HELLO")==0); CPPUNIT_ASSERT(strcmp(mc.str_buffer[3],"BYE")==0); + + //Check the content of the strings + CPPUNIT_ASSERT(strcmp(st1,"HOLA")==0); + CPPUNIT_ASSERT(strcmp(st2,"ADIOS")==0); + CPPUNIT_ASSERT(strcmp(st3,"HELLO")==0); + CPPUNIT_ASSERT(strcmp(st4,"BYE")==0); mem_collector_cleanup(&mc); diff --git a/src/dm/DispatchManager.cc b/src/dm/DispatchManager.cc index ea8796bbb0..89044f8e12 100644 --- a/src/dm/DispatchManager.cc +++ b/src/dm/DispatchManager.cc @@ -55,7 +55,7 @@ int DispatchManager::start() rc = pthread_create(&dm_thread,&pattr,dm_action_loop,(void *) this); return rc; -}; +} /* -------------------------------------------------------------------------- */ /* -------------------------------------------------------------------------- */ diff --git a/src/hm/HookManager.cc b/src/hm/HookManager.cc index 1fa91e9dc1..3ea2963d23 100644 --- a/src/hm/HookManager.cc +++ b/src/hm/HookManager.cc @@ -102,7 +102,7 @@ int HookManager::start() rc = pthread_create(&hm_thread,&pattr,hm_action_loop,(void *) this); return rc; -}; +} /* -------------------------------------------------------------------------- */ /* -------------------------------------------------------------------------- */ diff --git a/src/hm/HookManagerDriver.cc b/src/hm/HookManagerDriver.cc index a52c4844aa..7126e1971d 100644 --- a/src/hm/HookManagerDriver.cc +++ b/src/hm/HookManagerDriver.cc @@ -42,7 +42,7 @@ void HookManagerDriver::execute( } write(oss); -}; +} // ---------------------------------------------------------------------------- // ---------------------------------------------------------------------------- @@ -69,7 +69,7 @@ void HookManagerDriver::execute( } write(oss); -}; +} /* -------------------------------------------------------------------------- */ /* -------------------------------------------------------------------------- */ diff --git a/src/host/Host.cc b/src/host/Host.cc index 96bc19d685..bd44089dce 100644 --- a/src/host/Host.cc +++ b/src/host/Host.cc @@ -42,10 +42,9 @@ Host::Host( last_monitored(0), cluster(ClusterPool::DEFAULT_CLUSTER_NAME), host_template() - {}; + {} - -Host::~Host(){}; +Host::~Host(){} /* ************************************************************************ */ /* Host :: Database Access Functions */ @@ -413,7 +412,7 @@ ostream& operator<<(ostream& os, Host& host) os << host.to_xml(host_str); return os; -}; +} /* ------------------------------------------------------------------------ */ /* ------------------------------------------------------------------------ */ diff --git a/src/host/HostShare.cc b/src/host/HostShare.cc index e9b520e808..825536a652 100644 --- a/src/host/HostShare.cc +++ b/src/host/HostShare.cc @@ -276,7 +276,7 @@ ostream& operator<<(ostream& os, HostShare& hs) os << hs.to_xml(str); return os; -}; +} /* ------------------------------------------------------------------------ */ /* ------------------------------------------------------------------------ */ diff --git a/src/im/InformationManager.cc b/src/im/InformationManager.cc index 8bbf544f60..36f521dcd1 100644 --- a/src/im/InformationManager.cc +++ b/src/im/InformationManager.cc @@ -102,7 +102,7 @@ int InformationManager::start() rc = pthread_create(&im_thread,&pattr,im_action_loop,(void *) this); return rc; -}; +} /* -------------------------------------------------------------------------- */ /* -------------------------------------------------------------------------- */ diff --git a/src/im/InformationManagerDriver.cc b/src/im/InformationManagerDriver.cc index 4ce4d98299..e67ee1a75a 100644 --- a/src/im/InformationManagerDriver.cc +++ b/src/im/InformationManagerDriver.cc @@ -32,7 +32,7 @@ void InformationManagerDriver::monitor(int oid, os << "MONITOR " << oid << " " << host << " " << update << endl; write(os); -}; +} /* -------------------------------------------------------------------------- */ /* -------------------------------------------------------------------------- */ diff --git a/src/image/Image.cc b/src/image/Image.cc index 6a25c3a109..5a19ed6b24 100644 --- a/src/image/Image.cc +++ b/src/image/Image.cc @@ -50,7 +50,7 @@ Image::Image(int _uid, ImageTemplate * _image_template): { image_template = new ImageTemplate; } -}; +} Image::~Image() { @@ -58,7 +58,7 @@ Image::~Image() { delete image_template; } -}; +} /* ************************************************************************ */ /* Image :: Database Access Functions */ @@ -435,8 +435,7 @@ ostream& operator<<(ostream& os, Image& image) os << image.to_xml(image_str); return os; -}; - +} /* ------------------------------------------------------------------------ */ /* ------------------------------------------------------------------------ */ diff --git a/src/lcm/LifeCycleManager.cc b/src/lcm/LifeCycleManager.cc index be5aa4af37..d65fcb691c 100644 --- a/src/lcm/LifeCycleManager.cc +++ b/src/lcm/LifeCycleManager.cc @@ -55,7 +55,7 @@ int LifeCycleManager::start() rc = pthread_create(&lcm_thread,&pattr,lcm_action_loop,(void *) this); return rc; -}; +} /* -------------------------------------------------------------------------- */ /* -------------------------------------------------------------------------- */ diff --git a/src/log/Log.cc b/src/log/Log.cc index 80e7aa21d2..5b40c25db9 100644 --- a/src/log/Log.cc +++ b/src/log/Log.cc @@ -50,7 +50,7 @@ FileLog::FileLog(const string& file_name, { file.close(); } -}; +} /* -------------------------------------------------------------------------- */ /* -------------------------------------------------------------------------- */ diff --git a/src/log/NebulaLog.cc b/src/log/NebulaLog.cc index 8d477860d0..66f0218e15 100644 --- a/src/log/NebulaLog.cc +++ b/src/log/NebulaLog.cc @@ -23,4 +23,5 @@ Log * NebulaLog::logger; /* -------------------------------------------------------------------------- */ -/* -------------------------------------------------------------------------- */ \ No newline at end of file +/* -------------------------------------------------------------------------- */ + diff --git a/src/mad/Mad.cc b/src/mad/Mad.cc index 9a849f223a..ab564a7f95 100644 --- a/src/mad/Mad.cc +++ b/src/mad/Mad.cc @@ -164,11 +164,12 @@ int Mad::start() if ( sudo_execution == true ) { - rc = execlp("sudo","sudo","-H","-u",owner,executable,arguments,NULL); + rc = execlp("sudo","sudo","-H","-u",owner,executable,arguments, + (char *) NULL); } else { - rc = execlp(executable,executable,arguments,NULL); + rc = execlp(executable,executable,arguments,(char*)NULL); } goto error_exec; diff --git a/src/mad/MadManager.cc b/src/mad/MadManager.cc index d6be8f7aed..862fcc9724 100644 --- a/src/mad/MadManager.cc +++ b/src/mad/MadManager.cc @@ -29,7 +29,7 @@ MadManager::MadManager(vector& _mads):mad_conf(_mads) { pthread_mutex_init(&mutex,0); -}; +} /* -------------------------------------------------------------------------- */ /* -------------------------------------------------------------------------- */ @@ -37,7 +37,7 @@ MadManager::MadManager(vector& _mads):mad_conf(_mads) MadManager::~MadManager() { pthread_mutex_destroy(&mutex); -}; +} /* -------------------------------------------------------------------------- */ /* -------------------------------------------------------------------------- */ @@ -66,7 +66,7 @@ void MadManager::mad_manager_system_init() sigemptyset(&act.sa_mask); sigaction(SIGPIPE,&act,NULL); -}; +} /* -------------------------------------------------------------------------- */ /* -------------------------------------------------------------------------- */ @@ -335,4 +335,4 @@ void MadManager::listener() } } } -}; +} diff --git a/src/rm/RequestManagerImagePersistent.cc b/src/rm/RequestManagerImagePersistent.cc index 95d30756c3..1a52510d6c 100644 --- a/src/rm/RequestManagerImagePersistent.cc +++ b/src/rm/RequestManagerImagePersistent.cc @@ -137,7 +137,7 @@ error_authorize: error_persistent: image->unlock(); - oss << action_error(method_name, "MANAGE", "IMAGE", iid, NULL) + oss << action_error(method_name, "MANAGE", "IMAGE", iid, 0) << " Is the image public? An Image cannot be public and persistent."; goto error_common; diff --git a/src/rm/RequestManagerPoolInfo.cc b/src/rm/RequestManagerPoolInfo.cc index dc9e24c1e1..f52ee541fe 100644 --- a/src/rm/RequestManagerPoolInfo.cc +++ b/src/rm/RequestManagerPoolInfo.cc @@ -127,3 +127,5 @@ error_common: /* -------------------------------------------------------------------------- */ /* -------------------------------------------------------------------------- */ + + diff --git a/src/vnm/VirtualNetwork.cc b/src/vnm/VirtualNetwork.cc index 693f543087..6b758f4740 100644 --- a/src/vnm/VirtualNetwork.cc +++ b/src/vnm/VirtualNetwork.cc @@ -685,3 +685,4 @@ int VirtualNetwork::nic_attribute(VectorAttribute *nic, int vid) /* -------------------------------------------------------------------------- */ /* -------------------------------------------------------------------------- */ +