Commit ace76e42 authored by Hartmut Knaack's avatar Hartmut Knaack Committed by Jonathan Cameron

tools:iio:iio_utils: move up reset of sysfsfp

In iioutils_get_type() it is logically better fitting to have sysfsfp
assigned zero right after closing it.
Signed-off-by: default avatarHartmut Knaack <knaack.h@gmx.de>
Signed-off-by: default avatarJonathan Cameron <jic23@kernel.org>
parent 33ebcb21
......@@ -175,10 +175,10 @@ int iioutils_get_type(unsigned *is_signed,
goto error_free_filename;
}
sysfsfp = 0;
free(filename);
filename = 0;
sysfsfp = 0;
}
error_close_sysfsfp:
if (sysfsfp)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment