mirror of
https://github.com/Icinga/icinga2.git
synced 2025-07-24 22:24:44 +02:00
Merge pull request #5872 from Icinga/fix/incorrect-fclose
Replace incorrect fclose() call with pclose()
This commit is contained in:
commit
a5c95c8b48
@ -47,7 +47,8 @@ std::vector<String> icinga::GetBashCompletionSuggestions(const String& type, con
|
|||||||
boost::algorithm::trim_right_if(wline, boost::is_any_of("\r\n"));
|
boost::algorithm::trim_right_if(wline, boost::is_any_of("\r\n"));
|
||||||
result.push_back(wline);
|
result.push_back(wline);
|
||||||
}
|
}
|
||||||
fclose(fp);
|
|
||||||
|
pclose(fp);
|
||||||
|
|
||||||
/* Append a slash if there's only one suggestion and it's a directory */
|
/* Append a slash if there's only one suggestion and it's a directory */
|
||||||
if ((type == "file" || type == "directory") && result.size() == 1) {
|
if ((type == "file" || type == "directory") && result.size() == 1) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user