Skip to content

Commit 77394a4

Browse files
authored
Fix < 0 comparison for an unsigned long long (#5353)
* Fix < 0 comparison for an unsigned long long * Remove an unused file and fix init of a ULL
1 parent 148035f commit 77394a4

File tree

2 files changed

+2
-96
lines changed

2 files changed

+2
-96
lines changed

GoogleDataTransport/GDTCORLibrary/GDTCOREvent.m

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,11 +40,11 @@ + (NSNumber *)nextEventID {
4040
encoding:NSUTF8StringEncoding
4141
error:&error];
4242
const char *countChars = [countText UTF8String];
43-
unsigned long long count = -1;
43+
unsigned long long count = 0ULL;
4444
if (countChars) {
4545
count = strtoull([countText UTF8String], NULL, 10);
4646
}
47-
nextEventID = error || count < 0 ? 0 : count;
47+
nextEventID = error ? 0 : count;
4848
});
4949

5050
__block NSNumber *result;

GoogleDataTransport/GDTCORLibrary/Public/GDTCORSqlite.h

Lines changed: 0 additions & 94 deletions
This file was deleted.

0 commit comments

Comments
 (0)