Stage 1 of clang compiler warning patches.

This commit is contained in:
Euan Thoms
2015-10-31 14:10:03 +08:00
parent 0b490a00c6
commit 3c62cc744e
85 changed files with 185 additions and 165 deletions
+4 -4
View File
@@ -327,7 +327,7 @@ convention:
if (year && month && day)
[self setBday: [NSString stringWithFormat: @"%.4d-%.2d-%.2d",
year, month, day]];
(int)year, (int)month, (int)day]];
else
[self setBday: @""];
@@ -644,11 +644,11 @@ convention:
birthDay = [[self bday] asCalendarDate];
if (birthDay)
{
stringValue = [NSString stringWithFormat: @"%.4d", [birthDay yearOfCommonEra]];
stringValue = [NSString stringWithFormat: @"%.4d", (int)[birthDay yearOfCommonEra]];
[self _setValue: @"birthyear" to: stringValue inLDIFRecord: ldifRecord];
stringValue = [NSString stringWithFormat: @"%.2d", [birthDay monthOfYear]];
stringValue = [NSString stringWithFormat: @"%.2d", (int)[birthDay monthOfYear]];
[self _setValue: @"birthmonth" to: stringValue inLDIFRecord: ldifRecord];
stringValue = [NSString stringWithFormat: @"%.2d", [birthDay dayOfMonth]];
stringValue = [NSString stringWithFormat: @"%.2d", (int)[birthDay dayOfMonth]];
[self _setValue: @"birthday" to: stringValue inLDIFRecord: ldifRecord];
}
[self _setValue: @"description" to: [self note] inLDIFRecord: ldifRecord];
+1 -1
View File
@@ -59,7 +59,7 @@
[response setHeader: [self davContentType] forKey: @"content-type"];
[response setHeader: [NSString stringWithFormat:@" %d",
[data length]]
(int)[data length]]
forKey: @"content-length"];
[response setContent: data];
}
+3 -3
View File
@@ -268,9 +268,9 @@ Class SOGoContactSourceFolderK;
SOGoUser *currentUser;
id <SOGoSource> source;
if ([sourceID isEqualToString: @"personal"])
result = [NSException exceptionWithHTTPStatus: 403
reason: (@"folder '%@' cannot be deleted", sourceID)];
if ([sourceID isEqualToString: @"personal"]){
result = [NSException exceptionWithHTTPStatus: 403 reason: [NSString stringWithFormat: (@"folder '%@' cannot be deleted"), sourceID]];
}
else
{
result = nil;
+1 -1
View File
@@ -50,7 +50,7 @@
- (Class *) parsingClass
{
return [NGVCard class];
return (Class *)[NGVCard class];
}
/* content */
+1 -1
View File
@@ -45,7 +45,7 @@
- (Class *) parsingClass
{
return [NGVList class];
return (Class *)[NGVList class];
}
+1 -1
View File
@@ -94,7 +94,7 @@
{
if (![newDisplayName length])
newDisplayName = newName;
ASSIGN (displayName, newDisplayName);
ASSIGN (displayName, [newDisplayName mutableCopy]);
}
return self;