Commit 1fb554d7 authored by Dorian Guillois's avatar Dorian Guillois
Browse files

Remove valgrind warning for centreon connector perl.

parent f81df9a9
......@@ -19,9 +19,11 @@
*/
#include <cstdio>
#include <iostream>
#include <list>
#include <sstream>
#include "com/centreon/clib.hh"
#include "com/centreon/exceptions/basic.hh"
#include "com/centreon/io/file_stream.hh"
#include "com/centreon/process.hh"
#include "test/connector/misc.hh"
......@@ -149,6 +151,16 @@ int main() {
output.erase(pos, current.size());
}
try {
if (retval)
throw (basic_error()
<< "invalid output: size=" << output.size()
<< ", output=" << replace_null(output));
}
catch (std::exception const& e) {
std::cerr << "error: " << e.what() << std::endl;
}
clib::unload();
// Return check result.
return (retval);
......
......@@ -82,5 +82,10 @@ int main(int argc, char* argv[], char* env[]) {
catch (...) {
std::cerr << "unknown error" << std::endl;
}
// Unload.
embedded_perl::unload();
logging::engine::unload();
return (retval);
}
......@@ -86,5 +86,10 @@ int main(int argc, char* argv[], char* env[]) {
catch (...) {
std::cerr << "unknown error" << std::endl;
}
// Unload.
embedded_perl::unload();
logging::engine::unload();
return (retval);
}
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment