From 078fe68f2d74cacb182942325dc1e5944f3d6cda Mon Sep 17 00:00:00 2001 From: Christopher Michael Date: Mon, 17 May 2010 00:18:21 +0000 Subject: [PATCH] Make sscanf a bit more sane wrt the if statement. SVN revision: 48931 --- src/bin/e_acpi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/bin/e_acpi.c b/src/bin/e_acpi.c index d68a359ec..c8bb0bec4 100644 --- a/src/bin/e_acpi.c +++ b/src/bin/e_acpi.c @@ -151,7 +151,7 @@ _e_acpi_cb_server_data(void *data __UNUSED__, int type __UNUSED__, void *event) ev = event; /* parse out this acpi string into separate pieces */ - if (!(sscanf(ev->data, "%s %4s %8d %8d", device, bus, &sig, &status)) == 4) + if (sscanf(ev->data, "%s %4s %8d %8d", device, bus, &sig, &status) != 4) return 1; /* write out acutal acpi received data to stdout for debugging */