Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Fixing several warnings

  • Loading branch information...
commit a82260afb38bed5bf812d8e296af0890e3d22f3c 1 parent f808cef
@robbiehanson authored
View
2  Core/Categories/DDData.m
@@ -35,7 +35,7 @@ - (NSString *)hexStringValue
for (i = 0; i < [self length]; ++i)
{
- [stringBuffer appendFormat:@"%02x", (unsigned long)dataBuffer[i]];
+ [stringBuffer appendFormat:@"%02x", (unsigned int)dataBuffer[i]];
}
return [stringBuffer copy];
View
6 Core/Responses/HTTPAsyncFileResponse.m
@@ -199,7 +199,7 @@ - (BOOL)openFileAndSetupReadSource
// Perform the read
- HTTPLogVerbose(@"%@[%p]: Attempting to read %lu bytes from file", THIS_FILE, self, bytesToRead);
+ HTTPLogVerbose(@"%@[%p]: Attempting to read %lu bytes from file", THIS_FILE, self, (unsigned long)bytesToRead);
ssize_t result = read(fileFD, readBuffer + readBufferOffset, (size_t)bytesToRead);
@@ -220,7 +220,7 @@ - (BOOL)openFileAndSetupReadSource
}
else // (result > 0)
{
- HTTPLogVerbose(@"%@[%p]: Read %d bytes from file", THIS_FILE, self, result);
+ HTTPLogVerbose(@"%@[%p]: Read %lu bytes from file", THIS_FILE, self, (unsigned long)result);
readOffset += result;
readBufferOffset += result;
@@ -315,7 +315,7 @@ - (NSData *)readDataOfLength:(NSUInteger)length
{
NSUInteger dataLength = [data length];
- HTTPLogVerbose(@"%@[%p]: Returning data of length %lu", THIS_FILE, self, dataLength);
+ HTTPLogVerbose(@"%@[%p]: Returning data of length %lu", THIS_FILE, self, (unsigned long)dataLength);
fileOffset += dataLength;
View
2  Core/Responses/HTTPDataResponse.m
@@ -48,7 +48,7 @@ - (UInt64)offset
- (void)setOffset:(UInt64)offsetParam
{
- HTTPLogTrace2(@"%@[%p]: setOffset:%llu", THIS_FILE, self, offset);
+ HTTPLogTrace2(@"%@[%p]: setOffset:%lu", THIS_FILE, self, (unsigned long)offset);
offset = (NSUInteger)offsetParam;
}
View
4 Core/Responses/HTTPFileResponse.m
@@ -174,7 +174,7 @@ - (NSData *)readDataOfLength:(NSUInteger)length
// Perform the read
- HTTPLogVerbose(@"%@[%p]: Attempting to read %lu bytes from file", THIS_FILE, self, bytesToRead);
+ HTTPLogVerbose(@"%@[%p]: Attempting to read %lu bytes from file", THIS_FILE, self, (unsigned long)bytesToRead);
ssize_t result = read(fileFD, buffer, bytesToRead);
@@ -196,7 +196,7 @@ - (NSData *)readDataOfLength:(NSUInteger)length
}
else // (result > 0)
{
- HTTPLogVerbose(@"%@[%p]: Read %d bytes from file", THIS_FILE, self, result);
+ HTTPLogVerbose(@"%@[%p]: Read %ld bytes from file", THIS_FILE, self, (long)result);
fileOffset += result;
View
2  Samples/SecureWebSocketServer/SecureWebSocketServer/MyHTTPConnection.m
@@ -68,7 +68,7 @@ - (NSArray *)sslIdentityAndCertificates
if (wsHost == nil)
{
NSString *port = [NSString stringWithFormat:@"%hu", [asyncSocket localPort]];
- wsLocation = [NSString stringWithFormat:@"%@://localhost:%@%/service", scheme, port];
+ wsLocation = [NSString stringWithFormat:@"%@://localhost:%@/service", scheme, port];
}
else
{
View
2  Samples/SimpleWebSocketServer/MyHTTPConnection.m
@@ -34,7 +34,7 @@ @implementation MyHTTPConnection
if (wsHost == nil)
{
NSString *port = [NSString stringWithFormat:@"%hu", [asyncSocket localPort]];
- wsLocation = [NSString stringWithFormat:@"ws://localhost:%@%/service", port];
+ wsLocation = [NSString stringWithFormat:@"ws://localhost:%@/service", port];
}
else
{
Please sign in to comment.
Something went wrong with that request. Please try again.