Throughout Cygwin, use u_intN_t or uintN_t
Don't use u_char, u_short, u_int or u_long in Cygwin, unless it refers to the Winsock types. Use u_intN_t in BSD-based sources, unsigned char where strings are concerned, uintN_t otherwise. Also: * net.cc: Fix comment, we're not using u_long anymore. Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
This commit is contained in:
@@ -315,7 +315,7 @@ cygwin_rexec (char **ahost, unsigned short rport, char *name, char *pass,
|
||||
{
|
||||
struct sockaddr_in sin, sin2, from;
|
||||
struct hostent *hp;
|
||||
u_short port = 0;
|
||||
uint16_t port = 0;
|
||||
int s, timo = 1, s3;
|
||||
char c;
|
||||
static char ahostbuf[INTERNET_MAX_HOST_NAME_LENGTH + 1];
|
||||
@@ -371,7 +371,7 @@ retry:
|
||||
(void) close(s2);
|
||||
goto bad;
|
||||
}
|
||||
port = ntohs((u_short)sin2.sin_port);
|
||||
port = ntohs((uint16_t)sin2.sin_port);
|
||||
(void) sprintf(num, "%u", port);
|
||||
(void) write(s, num, strlen(num)+1);
|
||||
{ int len = sizeof (from);
|
||||
|
Reference in New Issue
Block a user