mirror of
https://github.com/open-simh/simh.git
synced 2026-02-26 17:03:56 +00:00
Compiler suggested cleanups
This commit is contained in:
3
scp.c
3
scp.c
@@ -5073,7 +5073,7 @@ char quote_char = 0;
|
||||
|
||||
while ((*iptr != 0) &&
|
||||
((quote && quoting) || ((isspace (*iptr) == 0) && (*iptr != mchar)))) {
|
||||
if (quote)
|
||||
if (quote) {
|
||||
if (quoting) {
|
||||
if (*iptr == quote_char)
|
||||
quoting = FALSE;
|
||||
@@ -5084,6 +5084,7 @@ while ((*iptr != 0) &&
|
||||
quote_char = *iptr;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (islower (*iptr) && uc)
|
||||
*optr = toupper (*iptr);
|
||||
else *optr = *iptr;
|
||||
|
||||
@@ -721,7 +721,7 @@ extern int32 sim_asynch_latency;
|
||||
extern int32 sim_asynch_inst_latency;
|
||||
|
||||
/* Thread local storage */
|
||||
#if defined(__GNUC__) && !defined(__APPLE__) && !defined(__hpux)
|
||||
#if defined(__GNUC__) && !defined(__APPLE__) && !defined(__hpux) && !defined(__OpenBSD__)
|
||||
#define AIO_TLS __thread
|
||||
#elif defined(_MSC_VER)
|
||||
#define AIO_TLS __declspec(thread)
|
||||
|
||||
@@ -903,11 +903,12 @@ if (rd)
|
||||
else select ((int) sock + 1, NULL, rw_p, er_p, &tz);
|
||||
if (FD_ISSET (sock, er_p))
|
||||
return -1;
|
||||
if (FD_ISSET (sock, rw_p))
|
||||
if (FD_ISSET (sock, rw_p)) {
|
||||
if (0 == getpeername (sock, (struct sockaddr *)&peername, &peernamesize))
|
||||
return 1;
|
||||
else
|
||||
return -1;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user