From f817b5727f6ba7fb7c2eb11250f64947ab29073e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ond=C5=99ej=20Ho=C5=A1ek?= Date: Fri, 22 Nov 2013 01:56:47 +0100 Subject: [PATCH] HLLib: remove spurious 0 from format string If a precision is given for an unsigned integer, padding always happens with zeroes. --- HLLib/VPKFile.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/HLLib/VPKFile.cpp b/HLLib/VPKFile.cpp index 629e107..02027ac 100644 --- a/HLLib/VPKFile.cpp +++ b/HLLib/VPKFile.cpp @@ -205,7 +205,7 @@ hlBool CVPKFile::MapDataStructures() memset(this->lpArchives, 0, this->uiArchiveCount * sizeof(VPKArchive)); for(hlUInt i = 0; i < this->uiArchiveCount; i++) { - hlInt iPrinted = sprintf(lpArchiveNumber, "%0.3u", i); + hlInt iPrinted = sprintf(lpArchiveNumber, "%.3u", i); if(iPrinted > 0) { strcat(lpArchiveNumber + iPrinted, lpExtension);