On Mon, Mar 02, 2015 at 01:11:01PM -0500, Stephen Chandler Paul wrote: > Signed-off-by: Stephen Chandler Paul <thatsly...@gmail.com> > --- > libwacom/libwacom-database.c | 12 ++++++------ > 1 file changed, 6 insertions(+), 6 deletions(-) > > diff --git a/libwacom/libwacom-database.c b/libwacom/libwacom-database.c > index a8b0396..f4cb82a 100644 > --- a/libwacom/libwacom-database.c > +++ b/libwacom/libwacom-database.c > @@ -212,11 +212,6 @@ libwacom_parse_stylus_keyfile(WacomDeviceDatabase *db, > const char *path) > if (error && error->code == > G_KEY_FILE_ERROR_INVALID_VALUE) > g_warning ("Stylus %s (%s) %s\n", stylus->name, > groups[i], error->message); > g_clear_error (&error); > - stylus->num_buttons = g_key_file_get_integer(keyfile, > groups[i], "Buttons", &error); > - if (stylus->num_buttons == 0 && error != NULL) { > - stylus->num_buttons = -1; > - g_clear_error (&error); > - } > stylus->has_lens = g_key_file_get_boolean(keyfile, > groups[i], "HasLens", &error); > if (error && error->code == > G_KEY_FILE_ERROR_INVALID_VALUE) > g_warning ("Stylus %s (%s) %s\n", stylus->name, > groups[i], error->message); > @@ -226,12 +221,17 @@ libwacom_parse_stylus_keyfile(WacomDeviceDatabase *db, > const char *path) > g_warning ("Stylus %s (%s) %s\n", stylus->name, > groups[i], error->message); > g_clear_error (&error); > } else { > - stylus->num_buttons = 0; > stylus->has_eraser = FALSE; > stylus->has_lens = FALSE; > stylus->has_wheel = FALSE; > } > > + stylus->num_buttons = g_key_file_get_integer(keyfile, > groups[i], "Buttons", &error); > + if (stylus->num_buttons == 0 && error != NULL) { > + stylus->num_buttons = -1; > + g_clear_error (&error); > + } > + > string_list = g_key_file_get_string_list (keyfile, groups[i], > "Axes", NULL, NULL); > if (string_list) { > WacomAxisTypeFlags axes = WACOM_AXIS_TYPE_NONE; > -- > 1.9.5
whoops. serves me right for not checking if the tests need updating... merged, with a test case on top, thanks. Cheers, Peter ------------------------------------------------------------------------------ Dive into the World of Parallel Programming The Go Parallel Website, sponsored by Intel and developed in partnership with Slashdot Media, is your hub for all things parallel software development, from weekly thought leadership blogs to news, videos, case studies, tutorials and more. Take a look and join the conversation now. http://goparallel.sourceforge.net/ _______________________________________________ Linuxwacom-devel mailing list Linuxwacom-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linuxwacom-devel