Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(42)

Unified Diff: third_party/sqlite/src/tool/showwal.c

Issue 1610963002: Import SQLite 3.10.2. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/sqlite/src/tool/showstat4.c ('k') | third_party/sqlite/src/tool/space_used.tcl » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/sqlite/src/tool/showwal.c
diff --git a/third_party/sqlite/src/tool/showwal.c b/third_party/sqlite/src/tool/showwal.c
index 35810c66a96ff875612068bf179995f43279ff77..33cc21896b4e2a3c9b615b5e63953ae52e39d83b 100644
--- a/third_party/sqlite/src/tool/showwal.c
+++ b/third_party/sqlite/src/tool/showwal.c
@@ -7,6 +7,9 @@
#include <sys/stat.h>
#include <fcntl.h>
+#define ISDIGIT(X) isdigit((unsigned char)(X))
+#define ISPRINT(X) isprint((unsigned char)(X))
+
#if !defined(_MSC_VER)
#include <unistd.h>
#else
@@ -159,7 +162,7 @@ static void print_byte_range(
if( i+j>nByte ){
fprintf(stdout, " ");
}else{
- fprintf(stdout,"%c", isprint(aData[i+j]) ? aData[i+j] : '.');
+ fprintf(stdout,"%c", ISPRINT(aData[i+j]) ? aData[i+j] : '.');
}
}
fprintf(stdout,"\n");
@@ -550,7 +553,7 @@ int main(int argc, char **argv){
print_wal_header(0);
continue;
}
- if( !isdigit(argv[i][0]) ){
+ if( !ISDIGIT(argv[i][0]) ){
fprintf(stderr, "%s: unknown option: [%s]\n", argv[0], argv[i]);
continue;
}
« no previous file with comments | « third_party/sqlite/src/tool/showstat4.c ('k') | third_party/sqlite/src/tool/space_used.tcl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698