mirror of
				https://github.com/isar/libmdbx.git
				synced 2025-10-31 15:38:57 +08:00 
			
		
		
		
	lmdb: fix format-string for 'entries' in mdb_chk.
Change-Id: I5a8c04e79416f22b64505be536b666620a9cce41
This commit is contained in:
		| @@ -68,7 +68,8 @@ unsigned userdb_count; | |||||||
| unsigned verbose = 1, quiet; | unsigned verbose = 1, quiet; | ||||||
| size_t pgcount; | size_t pgcount; | ||||||
|  |  | ||||||
| static void print(const char* msg, ...) { | static void __attribute__ ((format (printf, 1, 2))) | ||||||
|  | print(const char* msg, ...) { | ||||||
| 	if (! quiet) { | 	if (! quiet) { | ||||||
| 		va_list args; | 		va_list args; | ||||||
|  |  | ||||||
| @@ -79,7 +80,8 @@ static void print(const char* msg, ...) { | |||||||
| 	} | 	} | ||||||
| } | } | ||||||
|  |  | ||||||
| static void error(const char* msg, ...) { | static void __attribute__ ((format (printf, 1, 2))) | ||||||
|  | error(const char* msg, ...) { | ||||||
| 	if (! quiet) { | 	if (! quiet) { | ||||||
| 		va_list args; | 		va_list args; | ||||||
|  |  | ||||||
| @@ -339,7 +341,7 @@ static long process_db(MDB_dbi dbi, char *name, visitor *handler, int silent) | |||||||
| 					print(" %s", dbflags[i].name); | 					print(" %s", dbflags[i].name); | ||||||
| 		} | 		} | ||||||
| 		print(" (0x%x)\n", flags); | 		print(" (0x%x)\n", flags); | ||||||
| 		print(" - entries %zu\n", ms.ms_psize, ms.ms_entries); | 		print(" - page size %u, entries %zu\n", ms.ms_psize, ms.ms_entries); | ||||||
| 		print(" - b-tree depth %u, pages: branch %zu, leaf %zu, overflow %zu\n", | 		print(" - b-tree depth %u, pages: branch %zu, leaf %zu, overflow %zu\n", | ||||||
| 			  ms.ms_depth, ms.ms_branch_pages, ms.ms_leaf_pages, ms.ms_overflow_pages); | 			  ms.ms_depth, ms.ms_branch_pages, ms.ms_leaf_pages, ms.ms_overflow_pages); | ||||||
| 	} | 	} | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user