coverity: #1248105

Time of check time of use Signed-off-by: 's avatarChristian Brauner <christian.brauner@ubuntu.com>
parent e958e727
......@@ -571,7 +571,6 @@ static char *is_wlan(const char *ifname)
size_t len;
char *path;
FILE *f;
struct stat sb;
char *physname = NULL;
len = strlen(ifname) + strlen(PHYSNAME) - 1;
......@@ -580,10 +579,6 @@ static char *is_wlan(const char *ifname)
if (ret < 0 || (size_t)ret >= len)
goto bad;
ret = stat(path, &sb);
if (ret)
goto bad;
f = fopen(path, "r");
if (!f)
goto bad;
......
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