From ed26976ac51e423d900c2b409a3c5ec81800666b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marco=20Trevisan=20=28Trevi=C3=B1o=29?= Date: Tue, 16 Jun 2020 22:50:41 +0200 Subject: [PATCH] fpi-usb-transfer: Use the same values of libusb for transfer types --- libfprint/fpi-usb-transfer.c | 1 + libfprint/fpi-usb-transfer.h | 8 ++++---- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/libfprint/fpi-usb-transfer.c b/libfprint/fpi-usb-transfer.c index 74b5b1c..37033c8 100644 --- a/libfprint/fpi-usb-transfer.c +++ b/libfprint/fpi-usb-transfer.c @@ -105,6 +105,7 @@ fpi_usb_transfer_new (FpDevice * device) self = g_slice_new0 (FpiUsbTransfer); self->ref_count = 1; + self->type = FP_TRANSFER_NONE; self->device = device; diff --git a/libfprint/fpi-usb-transfer.h b/libfprint/fpi-usb-transfer.h index 40fd70c..dc7fdb6 100644 --- a/libfprint/fpi-usb-transfer.h +++ b/libfprint/fpi-usb-transfer.h @@ -47,10 +47,10 @@ typedef void (*FpiUsbTransferCallback)(FpiUsbTransfer *transfer, * Type of the transfer. */ typedef enum { - FP_TRANSFER_NONE = 0, - FP_TRANSFER_BULK, - FP_TRANSFER_CONTROL, - FP_TRANSFER_INTERRUPT, + FP_TRANSFER_NONE = -1, + FP_TRANSFER_CONTROL = 0, + FP_TRANSFER_BULK = 2, + FP_TRANSFER_INTERRUPT = 3, } FpiTransferType; /**