Skip to content

Commit a7d2818

Browse files
committed
Removed warnings introduced by Xcode 4.
1 parent 4a2a1b3 commit a7d2818

File tree

3 files changed

+6
-5
lines changed

3 files changed

+6
-5
lines changed

DirectoryReader.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
NSString* m_path; /**< File path. */
1414
}
1515

16+
- (id)initWithPath:(NSString*)path;
1617
- (BOOL)readDirectory:(NSArray**)files;
1718

1819
/**

FileReader.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ - (NSString*)readLine {
107107
*/
108108
- (NSString*)readLineBackwards {
109109

110-
if (m_totalFileLength == 0 || m_currentInset == 0 && m_chunkSize == 0) {
110+
if (m_totalFileLength == 0 || (m_currentInset == 0 && m_chunkSize == 0)) {
111111
return nil;
112112
}
113113

LineReaderAppDelegate.m

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ - (void)processSource {
115115
// Print lines to console.
116116
switch ([m_selectedReadMode intValue]) {
117117
case FORWARDS:
118-
while (line = [fileReader readLine]) {
118+
while ((line = [fileReader readLine])) {
119119
lineCount++;
120120
NSLog(@"%3.d: %@", lineCount, line);
121121
if (lineCount >= [m_maxNumLines intValue]) {
@@ -124,7 +124,7 @@ - (void)processSource {
124124
}
125125
break;
126126
case BACKWARDS:
127-
while (line = [fileReader readLineBackwards]) {
127+
while ((line = [fileReader readLineBackwards])) {
128128
lineCount++;
129129
NSLog(@"%3.d: %@", lineCount, line);
130130
if (lineCount >= [m_maxNumLines intValue]) {
@@ -141,15 +141,15 @@ - (void)processSource {
141141
// Do not print lines to console.
142142
switch ([m_selectedReadMode intValue]) {
143143
case FORWARDS:
144-
while (line = [fileReader readLine]) {
144+
while ((line = [fileReader readLine])) {
145145
lineCount++;
146146
if (lineCount >= [m_maxNumLines intValue]) {
147147
break;
148148
}
149149
}
150150
break;
151151
case BACKWARDS:
152-
while (line = [fileReader readLineBackwards]) {
152+
while ((line = [fileReader readLineBackwards])) {
153153
lineCount++;
154154
if (lineCount >= [m_maxNumLines intValue]) {
155155
break;

0 commit comments

Comments
 (0)