summaryrefslogtreecommitdiff
path: root/cmd/strsclnt
diff options
context:
space:
mode:
authorMartin Thomson <martin.thomson@gmail.com>2015-08-17 11:22:29 -0700
committerMartin Thomson <martin.thomson@gmail.com>2015-08-17 11:22:29 -0700
commitedfddd7b86ae3cc6b1b2440216d4b83cdd9f321b (patch)
tree243150dab7af42c35c08dd056ee854bad24a1bdd /cmd/strsclnt
parent03d2e2d3d9d618778194c3759dee4bc625310f55 (diff)
downloadnss-hg-edfddd7b86ae3cc6b1b2440216d4b83cdd9f321b.tar.gz
Bug 1182667 - Enable warnings as errors, r=rrelyea
Diffstat (limited to 'cmd/strsclnt')
-rw-r--r--cmd/strsclnt/strsclnt.c15
1 files changed, 7 insertions, 8 deletions
diff --git a/cmd/strsclnt/strsclnt.c b/cmd/strsclnt/strsclnt.c
index 43d121e27..f4825050f 100644
--- a/cmd/strsclnt/strsclnt.c
+++ b/cmd/strsclnt/strsclnt.c
@@ -498,7 +498,6 @@ init_thread_data(void)
PRBool useModelSocket = PR_TRUE;
-static const char stopCmd[] = { "GET /stop " };
static const char outHeader[] = {
"HTTP/1.0 200 OK\r\n"
"Server: Netscape-Enterprise/2.0a\r\n"
@@ -567,8 +566,8 @@ do_writes(
{
PRFileDesc * ssl_sock = (PRFileDesc *)a;
lockedVars * lv = (lockedVars *)b;
- int sent = 0;
- int count = 0;
+ unsigned int sent = 0;
+ int count = 0;
while (sent < bigBuf.len) {
@@ -712,7 +711,7 @@ PRInt32 lastFullHandshakePeerID;
void
myHandshakeCallback(PRFileDesc *socket, void *arg)
{
- PR_ATOMIC_SET(&lastFullHandshakePeerID, (PRInt32) arg);
+ PR_ATOMIC_SET(&lastFullHandshakePeerID, (PRInt32)((char *)arg - (char *)NULL));
}
#endif
@@ -732,7 +731,6 @@ do_connects(
PRFileDesc * tcp_sock = 0;
PRStatus prStatus;
PRUint32 sleepInterval = 50; /* milliseconds */
- SECStatus result;
int rv = SECSuccess;
PRSocketOptionData opt;
@@ -839,7 +837,8 @@ retry:
PR_snprintf(sockPeerIDString, sizeof(sockPeerIDString), "ID%d",
thisPeerID);
SSL_SetSockPeerID(ssl_sock, sockPeerIDString);
- SSL_HandshakeCallback(ssl_sock, myHandshakeCallback, (void*)thisPeerID);
+ SSL_HandshakeCallback(ssl_sock, myHandshakeCallback,
+ (char *)NULL + thisPeerID);
#else
/* force a full handshake by setting the no cache option */
SSL_OptionSet(ssl_sock, SSL_NO_CACHE, 1);
@@ -854,9 +853,9 @@ retry:
PR_ATOMIC_INCREMENT(&numConnected);
if (bigBuf.data != NULL) {
- result = handle_fdx_connection( ssl_sock, tid);
+ (void)handle_fdx_connection( ssl_sock, tid);
} else {
- result = handle_connection( ssl_sock, tid);
+ (void)handle_connection( ssl_sock, tid);
}
PR_ATOMIC_DECREMENT(&numConnected);