[PATCH 11/14] client/transfer: Return "error" for unknown status in status2str

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This can happen only if there is a bug in obexd code.
This fix following build error:

  CC     obexd/client/obexd-transfer.o
obexd/client/transfer.c: In function ‘status2str’:
obexd/client/transfer.c:277:1: error: control reaches end of non-void
    function [-Werror=return-type]
---
 obexd/client/transfer.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/obexd/client/transfer.c b/obexd/client/transfer.c
index 99a17e9..5a8d4f2 100644
--- a/obexd/client/transfer.c
+++ b/obexd/client/transfer.c
@@ -272,6 +272,7 @@ static const char *status2str(uint8_t status)
 	case TRANSFER_STATUS_COMPLETE:
 		return "complete";
 	case TRANSFER_STATUS_ERROR:
+	default:
 		return "error";
 	}
 }
-- 
1.8.4

--
To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Bluez Devel]     [Linux Wireless Networking]     [Linux Wireless Personal Area Networking]     [Linux ATH6KL]     [Linux USB Devel]     [Linux Media Drivers]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux