diff --git a/sync/device.c b/sync/device.c index e8730d2..26e1186 100644 --- a/sync/device.c +++ b/sync/device.c @@ -20,7 +20,7 @@ static const char *sync_track_path(const char *base, const char *name) #ifndef SYNC_PLAYER -static SOCKET server_connect(const char *host, int nport) +static SOCKET server_connect(const char *host, unsigned short nport) { struct hostent *he; struct sockaddr_in sa; @@ -222,7 +222,7 @@ static int purge_and_rerequest(struct sync_device *d) return 0; } -int sync_connect(struct sync_device *d, const char *host, int port) +int sync_connect(struct sync_device *d, const char *host, unsigned short port) { if (d->sock != INVALID_SOCKET) closesocket(d->sock); diff --git a/sync/sync.h b/sync/sync.h index c77c40e..d571ec1 100644 --- a/sync/sync.h +++ b/sync/sync.h @@ -23,7 +23,7 @@ struct sync_cb { }; void sync_set_callbacks(struct sync_device *, struct sync_cb *, void *); #define SYNC_DEFAULT_PORT 1338 -int sync_connect(struct sync_device *, const char *, int port); +int sync_connect(struct sync_device *, const char *, unsigned short); int sync_update(struct sync_device *, int); #endif /* !defined(SYNC_PLAYER) */