Bastien Nocera
9cca501650
lib: Fix new BUG_ON() implementation
...
A thinko reversed the meaning of the BUG_ON() condition. This fixes
the inverted implementation in commit
ff09456cf5
.
2018-05-25 16:12:29 +02:00
Bastien Nocera
2481cbe4ab
poll: Add some details about how mainloop integration works
2018-05-25 15:58:29 +02:00
Bastien Nocera
bc3959d1e0
lib: Fix internal deprecation warning
...
Remove deprecation warning that comes from an internal function, it
serves no purpose, and the function itself is deprecated.
Follow-up from commit 1f0079a274
.
2018-05-25 13:45:13 +02:00
Bastien Nocera
1ac815e457
examples: Fix integer overflow warnings
2018-05-25 13:40:33 +02:00
Bastien Nocera
55b83062d0
img: Fix fd leaks
...
Spotted by maddin200@aol.com
https://bugs.freedesktop.org/show_bug.cgi?id=90197
2018-05-25 13:30:35 +02:00
Mark Harfouche
391f77ce5e
aes1610: Fix compilation warning in aes1610
...
Fixes:
drivers/aes1610.c:736:34: warning: ‘stop_reader’ defined but not used [-Wunused-const-variable=]
https://bugs.freedesktop.org/show_bug.cgi?id=105429
2018-05-25 13:21:17 +02:00
Bastien Nocera
bc30a3d2e5
aes2501: Fix state machine never using "init_3" state
...
This fixes this warning by the same token:
drivers/aes2501.c:671:34: warning: ‘init_3’ defined but not used [-Wunused-const-variable=]
https://bugs.freedesktop.org/show_bug.cgi?id=105429
2018-05-25 13:21:17 +02:00
Bastien Nocera
ff5de4ff03
lib: Replace open-coded array_n_elements()
...
Replace it with glib's version, which already exists.
https://bugs.freedesktop.org/show_bug.cgi?id=106280
2018-05-25 13:20:34 +02:00
Bastien Nocera
f433a4d67c
upekts: Fix compilation warning
...
libfprint/drivers/upekts.c: In function ‘alloc_send_cmd_transfer’:
libfprint/drivers/upekts.c:161:2: warning: ‘strncpy’ output truncated before terminating nul copying 4 bytes from a string of the same length [-Wstringop-truncation]
strncpy(buf, "Ciao", 4);
^~~~~~~~~~~~~~~~~~~~~~~
Replace with memcpy() to only copy the 4 bytes we need.
https://bugs.freedesktop.org/show_bug.cgi?id=106281
2018-05-25 13:19:31 +02:00
Bastien Nocera
994061af44
drivers: Simplify headers
...
Remove all the headers already included through "fp_internal.h" such as
<libusb.h> and <errno.h>, include "assembling.h" and "driver_ids.h" there
as well to avoid doing it in (almost) every driver.
2018-05-24 17:02:15 +02:00
Bastien Nocera
501020921e
vfs301_proto: Use GLib helpers
...
No need to roll out own min() implementation, or use the bare assert().
2018-05-24 17:00:17 +02:00
Bastien Nocera
53c09405b2
etes603: Use GLib's g_assert()
...
Instead of requiring assert.h to be included.
2018-05-24 16:57:14 +02:00
Bastien Nocera
1f0079a274
data: Mark all the fp_dscv_print functions as deprecated
...
As this is pretty much copy/pasted in fprintd, and should instead be
implemented by whatever system actually stores the data, rather than
in a generic but not quite "fits-all-purpose" way.
https://bugs.freedesktop.org/show_bug.cgi?id=106550
2018-05-24 13:21:40 +02:00
Bastien Nocera
15afe43cf0
examples: Replace deprecated fp_set_debug()
2018-05-24 12:43:53 +02:00
Bastien Nocera
eb8f7ba3b2
lib: Mark fp_set_debug() as deprecated
...
As per the documentation.
2018-05-24 12:42:18 +02:00
Bastien Nocera
901a6f7fed
lib: Add macro for deprecated functions
2018-05-24 12:41:35 +02:00
Bastien Nocera
fc92f62136
build: Remove the need to modify sources for new drivers
...
Instead of having to modify both fp_internal.h to list each driver
definition structure, and core.c to add those drivers to arrays we
can loop over, generate both of those using meson.
2018-05-24 12:23:39 +02:00
Bastien Nocera
ff09456cf5
lib: Use g_assert* to implement BUG() and BUG_ON() assertions
2018-05-23 19:14:33 +02:00
Bastien Nocera
32fcfde86b
lib: Use GLib and libusb directly for debug output
...
Use GLib internally to output debug information, and tell about
libusb's LIBUSB_DEBUG envvar for libusb debug.
fp_set_debug() is now a no-op.
https://bugs.freedesktop.org/show_bug.cgi?id=106552
2018-05-23 19:13:08 +02:00
Bastien Nocera
363a1b3371
lib: Replace empty fp_dbg() calls
...
GLib won't like them, so use G_DEBUG_HERE() instead.
2018-05-23 19:11:07 +02:00
Bastien Nocera
c376c6fb02
lib: Fix type mismatch warnings in debug output
2018-05-23 19:11:05 +02:00
Bastien Nocera
8e6e23b8d0
build: Always enable debugging logging
...
We shouldn't need to specifically enable debug logging to get useful
data out of a compiled libfprint either, so always enable debugging
output. It will still be switched off at runtime, by default.
2018-05-23 19:11:02 +02:00
Bastien Nocera
63e5d56441
build: Always allow switching log level at runtime
...
There are no parts of libfprint that are so resource intensive that we'd
want to disable logging. This avoids (hopefully rare) cases where
compiled versions of libfprint are distributed with logging completely
disabled, and thus can't be debugged.
2018-05-23 19:10:58 +02:00
Bastien Nocera
e9bfd943fc
docs: Mark a few FP_VERIFY_MATCH as constant
...
Add "%" prefix to mark it as a constant in the docs.
2018-05-23 15:18:34 +02:00
Bastien Nocera
614e2286c2
docs: Fix typo in fp_enroll_finger_img() API docs
...
Missing ":" after argument name.
2018-05-23 15:18:34 +02:00
Bastien Nocera
768a74c4bf
docs: Remove transfer information from fp_dev_open()
...
There's no GObject usage in the public API.
2018-05-23 15:18:34 +02:00
Bastien Nocera
612e9e11de
docs: Document async function callbacks
2018-05-23 15:18:34 +02:00
Bastien Nocera
06c72d54be
poll: Add missing API docs for polling functions
2018-05-23 15:18:34 +02:00
Bastien Nocera
be68bacc94
lib: Merge two other async callback types
...
Merge fp_capture_cb and fp_verify_cb.
https://bugs.freedesktop.org/show_bug.cgi?id=106551
2018-05-23 15:18:34 +02:00
Bastien Nocera
317d7bc988
lib: Simplify fp_*_stop_cb callback definitions
...
They're all the same, so merge them into a single fp_operation_stop_cb.
https://bugs.freedesktop.org/show_bug.cgi?id=106551
2018-05-23 13:39:10 +02:00
Bastien Nocera
b44e417bca
docs: Fix '\sa' doxygen references
2018-05-23 13:39:10 +02:00
Bastien Nocera
9d67ce484d
lib: Make inline functions real functions
...
Otherwise they will not be parsed by gtk-doc and documented.
2018-05-23 13:39:10 +02:00
Bastien Nocera
78b8602cf6
lib: Make fp_minutia an opaque structure
...
Nothing uses the elements of the structure, so make it opaque.
2018-05-23 13:39:10 +02:00
Bastien Nocera
83a0a7681b
img: Make fpi_img_detect_minutiae() static
...
It's unused outside img.c, so mark it as static.
2018-05-23 13:39:10 +02:00
Bastien Nocera
c5e0e41ce7
docs: Add documentation for opaque structures
2018-05-23 13:39:00 +02:00
Bastien Nocera
b3fe4a1e91
docs: Update API documentation
...
Fixes to layout, dead links, typography, and more.
Thanks to Benjamin Berg <bberg@redhat.com> for the thorough review
2018-05-18 05:51:58 +02:00
Bastien Nocera
f59bf389d9
INSTALL: Update for Meson
2018-05-18 01:16:30 +02:00
Bastien Nocera
231b8f9f92
doc: Port from Doxygen to gtk-doc
...
Split the introduction into separate chapters, add filler documentation
for async functions, fix mismatched function arguments.
2018-05-17 17:39:51 +02:00
Bastien Nocera
dac153d24a
build: Port to meson
...
And remove the autotools. Faster, cleaner.
https://bugs.freedesktop.org/show_bug.cgi?id=106514
2018-05-15 10:46:54 +02:00
Bastien Nocera
3661d146a7
drivers: Remove UPEKE2 driver
...
The device is already handled by upektc_img driver, and its sources
still exist in git if needed.
https://bugs.freedesktop.org/show_bug.cgi?id=106514
2018-05-15 10:46:54 +02:00
Bastien Nocera
3bf55a3e07
examples: Fix compile-time warning
...
Fix "function declaration isn’t a prototype" warning
2018-05-14 17:35:51 +02:00
Bastien Nocera
5226467fc2
build: Make NSS (and URU4000) driver optional
...
In case NSS isn't available.
https://bugs.freedesktop.org/show_bug.cgi?id=106278
2018-05-11 11:13:25 +02:00
Mark Harfouche
54deaa1b24
mindtct: Fix compilation warnings
...
nbis/mindtct/morph.c:152:4: warning: this ‘if’ clause does not guard... [-Wmisleading-indentation]
nbis/mindtct/morph.c:176:4: warning: this ‘if’ clause does not guard... [-Wmisleading-indentation]
nbis/mindtct/morph.c:200:4: warning: this ‘if’ clause does not guard... [-Wmisleading-indentation]
nbis/mindtct/morph.c:222:4: warning: this ‘if’ clause does not guard... [-Wmisleading-indentation]
https://bugs.freedesktop.org/show_bug.cgi?id=105429
2018-03-11 22:43:04 +01:00
Mark Harfouche
7ff667f58d
examples: Fix memory leaked by device discovery
...
https://bugs.freedesktop.org/show_bug.cgi?id=105427
2018-03-11 13:46:00 +01:00
Mark Harfouche
58ba9b02ed
lib: Fix memory leak patch in device discovery
...
libusb_free_device_list() needs to be called on the list of USB devices
obtained through libusb_get_device_list() or the list and its elements
will be leaked.
https://bugs.freedesktop.org/show_bug.cgi?id=105427
2018-03-11 13:43:58 +01:00
Hans de Goede
d35da0ce99
fprint-list-udev-rules: Add some unsupported Validity Sensors readers to the whitelist
2017-12-12 10:51:43 +01:00
Hans de Goede
041e6a1078
fprint-list-udev-rules: Add some unsupported Elantech readers to the whitelist
2017-12-12 10:51:43 +01:00
Hans de Goede
1c73c36ed7
fprint-list-udev-rules: Remove white-list entries which have a driver now
...
Remove 2 entries from the whitelist for finger-print models for which
we have a driver now, so they no longer need to be on the whitelist.
2017-12-12 10:51:43 +01:00
Anton Eliasson
69de32f700
vfs5011: Don't submit an image if there was an error capturing it
2017-12-03 13:12:53 -08:00
Alan Davidson
4bfee76ead
Fix security hole: zero out memory when allocated
2017-12-03 13:11:48 -08:00