core: drop an unnecessary pointer assignment
authorBartosz Golaszewski <bgolaszewski@baylibre.com>
Thu, 28 Feb 2019 14:28:50 +0000 (15:28 +0100)
committerBartosz Golaszewski <bgolaszewski@baylibre.com>
Thu, 28 Feb 2019 14:28:50 +0000 (15:28 +0100)
The whole line structure is zeroed in the line above, so there's no
need to set the fd_handle pointer to NULL.

Signed-off-by: Bartosz Golaszewski <bgolaszewski@baylibre.com>
src/lib/core.c

index 347f92b35857b447e8f3de6c84ebf08e65cdd1cc..05e5a46b2a4235720257a5c87a474406f8da655b 100644 (file)
@@ -259,7 +259,6 @@ gpiod_chip_get_line(struct gpiod_chip *chip, unsigned int offset)
                        return NULL;
 
                memset(line, 0, sizeof(*line));
-               line->fd_handle = NULL;
 
                line->offset = offset;
                line->chip = chip;