Skip to content

Commit

Permalink
group: fix warning
Browse files Browse the repository at this point in the history
Fixes:

	-bash-5.2$ make
	(...)
	cc -Werror -DNVERBOSE -fPIC -Wall -Wextra -D_GNU_SOURCE -DVERSION=23 -DPREFIX=/usr/local  -c -o group.o /home/freebox/src/iamroot/group.c
	/home/freebox/src/iamroot/group.c:61:12: error: unused variable 'fd' [-Werror,-Wunused-variable]
	        const int fd = fileno(f);
	                  ^
	/home/freebox/src/iamroot/group.c:119:12: error: unused variable 'fd' [-Werror,-Wunused-variable]
	        const int fd = fileno(f);
	                  ^
	2 errors generated.
  • Loading branch information
gportay committed Oct 9, 2024
1 parent 697bbd1 commit f94f03d
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions group.c
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ struct group *fgetgrent(FILE *f)
{
const int fd = fileno(f);
struct group *ret;
(void)fd;

ret = _fgetgrent(f);

Expand Down Expand Up @@ -118,6 +119,7 @@ int putgrent(const struct group *gr, FILE *f)
{
const int fd = fileno(f);
int ret;
(void)fd;

ret = _putgrent(gr, f);

Expand Down

0 comments on commit f94f03d

Please sign in to comment.