From b85385a058cf5f9f1e83b91be1c85d1f1931f1c5 Mon Sep 17 00:00:00 2001 From: iceman1001 Date: Tue, 3 May 2016 09:16:05 +0200 Subject: [PATCH] CHG: removed a warning about unused variable. Lets see if perror works. --- client/uart.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/client/uart.c b/client/uart.c index 5aefcf76..508eb672 100644 --- a/client/uart.c +++ b/client/uart.c @@ -119,7 +119,12 @@ void uart_close(const serial_port sp) { fl.l_start = 0; fl.l_len = 0; fl.l_pid = getpid(); + + // Does the system allows us to place a lock on this file descriptor int err = fcntl(spu->fd, F_SETLK, &fl); + if ( err == -1) { + perror("fcntl"); + } close(spu->fd); free(sp); } -- 2.39.2