Skip to content

Commit

Permalink
network: change type of 'i' to unsigned int
Browse files Browse the repository at this point in the history
This only happens on Appveyor with Visual C compiler.
```
C:\projects\libiio\network.c(1458): error C2220: warning treated as error - no 'object' file generated [C:\projects\libiio\build-win64\iio.vcxproj]
C:\projects\libiio\network.c(1458): warning C4267: 'function' : conversion from 'size_t' to 'unsigned int', possible loss of data [C:\projects\libiio\build-win64\iio.vcxproj]
```

Warning is reasonable. So, change type of 'i'.

Signed-off-by: Alexandru Ardelean <[email protected]>
  • Loading branch information
commodo committed Oct 13, 2020
1 parent bf45225 commit fea0a70
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion network.c
Original file line number Diff line number Diff line change
Expand Up @@ -1293,7 +1293,8 @@ struct iio_context * network_create_context(const char *host)
struct iio_context *ctx;
struct iiod_client *iiod_client;
struct iio_context_pdata *pdata;
size_t i, len, uri_len;
size_t len, uri_len;
unsigned int i;
int fd, ret;
char *description, *uri;
#ifdef _WIN32
Expand Down

0 comments on commit fea0a70

Please sign in to comment.