summaryrefslogtreecommitdiffstats
path: root/plugins/check_apt.c
diff options
context:
space:
mode:
authorLorenz Kästle <12514511+RincewindsHat@users.noreply.github.com>2025-09-15 16:09:40 +0200
committerGitHub <noreply@github.com>2025-09-15 16:09:40 +0200
commit601a48a63e745817cf2a4c7f3ca526e393dd3fb8 (patch)
treeed011d8f2bfcde8750bca64c0f69407df4bd6444 /plugins/check_apt.c
parent8ef825d85fb4d09c32ca44c545d6eb8d995ddea4 (diff)
parent15ecdb73ce5cda54f824e5a63ee8e801bf16a996 (diff)
downloadmonitoring-plugins-601a48a63e745817cf2a4c7f3ca526e393dd3fb8.tar.gz
Merge pull request #2150 from RincewindsHat/refactor/lib
general refactorin in lib, more local variables, real booleans
Diffstat (limited to 'plugins/check_apt.c')
-rw-r--r--plugins/check_apt.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/plugins/check_apt.c b/plugins/check_apt.c
index e840184b..ab66a8d2 100644
--- a/plugins/check_apt.c
+++ b/plugins/check_apt.c
@@ -310,8 +310,8 @@ run_upgrade_result run_upgrade(const upgrade_type upgrade, const char *do_includ
310 die(STATE_UNKNOWN, _("%s: Error compiling regexp: %s"), progname, rerrbuf); 310 die(STATE_UNKNOWN, _("%s: Error compiling regexp: %s"), progname, rerrbuf);
311 } 311 }
312 312
313 struct output chld_out; 313 output chld_out;
314 struct output chld_err; 314 output chld_err;
315 char *cmdline = NULL; 315 char *cmdline = NULL;
316 cmdline = construct_cmdline(upgrade, upgrade_opts); 316 cmdline = construct_cmdline(upgrade, upgrade_opts);
317 if (input_filename != NULL) { 317 if (input_filename != NULL) {
@@ -410,8 +410,8 @@ int run_update(char *update_opts) {
410 /* run the update */ 410 /* run the update */
411 cmdline = construct_cmdline(NO_UPGRADE, update_opts); 411 cmdline = construct_cmdline(NO_UPGRADE, update_opts);
412 412
413 struct output chld_out; 413 output chld_out;
414 struct output chld_err; 414 output chld_err;
415 result = np_runcmd(cmdline, &chld_out, &chld_err, 0); 415 result = np_runcmd(cmdline, &chld_out, &chld_err, 0);
416 /* apt-get update changes exit status if it can't fetch packages. 416 /* apt-get update changes exit status if it can't fetch packages.
417 * since we were explicitly asked to do so, this is treated as 417 * since we were explicitly asked to do so, this is treated as