diff options
author | Richard Hughes <richard@hughsie.com> | 2010-01-11 15:56:53 +0000 |
---|---|---|
committer | Richard Hughes <richard@hughsie.com> | 2010-01-11 15:56:53 +0000 |
commit | e93895a257b1215fa0ab0e3667e900df7709fa60 (patch) | |
tree | cf35e4044e8cd729576ca48bf5e997687a827ab0 | |
parent | 7222042da34765c3d0950ee8484df91b1a0910f9 (diff) |
Use a fallback for the capability bit when checking the lid status. Fixes #25041
-rw-r--r-- | src/linux/dkp-input.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/linux/dkp-input.c b/src/linux/dkp-input.c index 0ea72b5..e213033 100644 --- a/src/linux/dkp-input.c +++ b/src/linux/dkp-input.c @@ -183,7 +183,12 @@ dkp_input_coldplug (DkpInput *input, DkpDaemon *daemon, GUdevDevice *d) path = g_build_filename (native_path, "../capabilities/sw", NULL); if (!g_file_test (path, G_FILE_TEST_EXISTS)) { egg_debug ("not a switch [%s]", path); - goto out; + g_free (path); + path = g_build_filename (native_path, "capabilities/sw", NULL); + if (!g_file_test (path, G_FILE_TEST_EXISTS)) { + egg_debug ("not a switch [%s]", path); + goto out; + } } /* get caps */ |