Fix error name collision.
This commit is contained in:
parent
28c7a64bd2
commit
d9cdb7ef83
@ -39,21 +39,21 @@ __END_DECLS
|
|||||||
|
|
||||||
#ifdef CRASHLYTICS
|
#ifdef CRASHLYTICS
|
||||||
#define MPError(error_, message, ...) ({ \
|
#define MPError(error_, message, ...) ({ \
|
||||||
NSError *error = error_; \
|
NSError *__error = error_; \
|
||||||
err( message @"%@%@", ##__VA_ARGS__, error && [message length]? @"\n": @"", [error fullDescription]?: @"" ); \
|
err( message @"%@%@", ##__VA_ARGS__, __error && [message length]? @"\n": @"", [__error fullDescription]?: @"" ); \
|
||||||
\
|
\
|
||||||
if ([[MPConfig get].sendInfo boolValue]) { \
|
if ([[MPConfig get].sendInfo boolValue]) { \
|
||||||
[[Crashlytics sharedInstance] recordError:error withAdditionalUserInfo:@{ \
|
[[Crashlytics sharedInstance] recordError:__error withAdditionalUserInfo:@{ \
|
||||||
@"location": strf( @"%@:%d %@", @(basename((char *)__FILE__)), __LINE__, NSStringFromSelector(_cmd) ), \
|
@"location": strf( @"%@:%d %@", @(basename((char *)__FILE__)), __LINE__, NSStringFromSelector(_cmd) ), \
|
||||||
}]; \
|
}]; \
|
||||||
} \
|
} \
|
||||||
error; \
|
__error; \
|
||||||
})
|
})
|
||||||
#else
|
#else
|
||||||
#define MPError(error_, message, ...) ({ \
|
#define MPError(error_, message, ...) ({ \
|
||||||
NSError *error = error_; \
|
NSError *__error = error_; \
|
||||||
err( message @"%@%@", ##__VA_ARGS__, error? @"\n": @"", [error fullDescription]?: @"" ); \
|
err( message @"%@%@", ##__VA_ARGS__, __error? @"\n": @"", [__error fullDescription]?: @"" ); \
|
||||||
error; \
|
__error; \
|
||||||
})
|
})
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user