mirror of
https://github.com/pandorafms/pandorafms.git
synced 2025-07-27 15:54:29 +02:00
2012-01-30 Ramon Novoa <rnovoa@artica.es>
* modules/pandora_module_regexp.cc: Do not open the file in the constructor to avoid trouble if other modules modify it before the regexp module runs. git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@5448 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
parent
dc557bdd94
commit
9202627292
@ -1,3 +1,9 @@
|
|||||||
|
2012-01-30 Ramon Novoa <rnovoa@artica.es>
|
||||||
|
|
||||||
|
* modules/pandora_module_regexp.cc: Do not open the file in the
|
||||||
|
constructor to avoid trouble if other modules modify it before
|
||||||
|
the regexp module runs.
|
||||||
|
|
||||||
2012-01-19 Ramon Novoa <rnovoa@artica.es>
|
2012-01-19 Ramon Novoa <rnovoa@artica.es>
|
||||||
|
|
||||||
* modules/pandora_module_odbc.cc: Check for NULL pointers.
|
* modules/pandora_module_odbc.cc: Check for NULL pointers.
|
||||||
|
@ -47,12 +47,10 @@ Pandora_Module_Regexp::Pandora_Module_Regexp (string name, string source, string
|
|||||||
pandoraLog ("Invalid regular expression %s", pattern.c_str ());
|
pandoraLog ("Invalid regular expression %s", pattern.c_str ());
|
||||||
}
|
}
|
||||||
|
|
||||||
// Open the file and skip to the end
|
// Check whether the file can be opened
|
||||||
this->file.open (source.c_str ());
|
this->file.open (source.c_str ());
|
||||||
if (this->file.is_open ()) {
|
if (this->file.is_open ()) {
|
||||||
if (no_seek_eof == 0) {
|
this->file.close ();
|
||||||
this->file.seekg (0, ios_base::end);
|
|
||||||
}
|
|
||||||
} else {
|
} else {
|
||||||
pandoraLog ("Error opening file %s", source.c_str ());
|
pandoraLog ("Error opening file %s", source.c_str ());
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user