From 2b8c524928520f5e780e8baf9325bf1d0d4861a0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marco=20Trevisan=20=28Trevi=C3=B1o=29?= Date: Wed, 4 Dec 2019 13:25:27 +0100 Subject: [PATCH] cleanup: Use static functions for non-declared methods --- libfprint/drivers/aes2501.c | 2 +- libfprint/drivers/elan.c | 4 ++-- libfprint/fp-device.c | 2 +- libfprint/fpi-usb-transfer.c | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/libfprint/drivers/aes2501.c b/libfprint/drivers/aes2501.c index 1aa0538..57b0cca 100644 --- a/libfprint/drivers/aes2501.c +++ b/libfprint/drivers/aes2501.c @@ -686,7 +686,7 @@ enum activate_states { ACTIVATE_NUM_STATES, }; -void +static void activate_read_regs_cb (FpImageDevice *dev, GError *error, unsigned char *regs, void *user_data) { diff --git a/libfprint/drivers/elan.c b/libfprint/drivers/elan.c index 7c7fb26..90a0306 100644 --- a/libfprint/drivers/elan.c +++ b/libfprint/drivers/elan.c @@ -41,7 +41,7 @@ #include "drivers_api.h" #include "elan.h" -unsigned char +static unsigned char elan_get_pixel (struct fpi_frame_asmbl_ctx *ctx, struct fpi_frame *frame, unsigned int x, unsigned int y) @@ -91,7 +91,7 @@ G_DECLARE_FINAL_TYPE (FpiDeviceElan, fpi_device_elan, FPI, DEVICE_ELAN, FpImageDevice); G_DEFINE_TYPE (FpiDeviceElan, fpi_device_elan, FP_TYPE_IMAGE_DEVICE); -int +static int cmp_short (const void *a, const void *b) { return (int) (*(short *) a - *(short *) b); diff --git a/libfprint/fp-device.c b/libfprint/fp-device.c index 334b998..2f706b3 100644 --- a/libfprint/fp-device.c +++ b/libfprint/fp-device.c @@ -1386,7 +1386,7 @@ typedef struct FpDevice *device; } FpDeviceTimeoutSource; -void +static void timeout_finalize (GSource *source) { FpDeviceTimeoutSource *timeout_source = (FpDeviceTimeoutSource *) source; diff --git a/libfprint/fpi-usb-transfer.c b/libfprint/fpi-usb-transfer.c index 08e75cb..99fe3d4 100644 --- a/libfprint/fpi-usb-transfer.c +++ b/libfprint/fpi-usb-transfer.c @@ -298,7 +298,7 @@ fpi_usb_transfer_fill_interrupt_full (FpiUsbTransfer *transfer, transfer->free_buffer = free_func; } -void +static void transfer_finish_cb (GObject *source_object, GAsyncResult *res, gpointer user_data) { GError *error = NULL;