瀏覽代碼

Merge branch 'main' into issigkeys

Martijn Laan 4 月之前
父節點
當前提交
33f6f4416d
共有 4 個文件被更改,包括 14 次插入3 次删除
  1. 4 2
      Components/Lzma2/Util/7z/7zMain.c
  2. 9 1
      ISHelp/isetup.xml
  3. 二進制
      Projects/Src/Compression.SevenZipDecoder/7zDecode/IS7zDec.obj
  4. 1 0
      whatsnew.htm

+ 4 - 2
Components/Lzma2/Util/7z/7zMain.c

@@ -3,6 +3,7 @@
 
 /* Changes by Martijn Laan for Inno Setup:
    -Use CP_UTF8 in PrintString
+   -Fix Utf16_To_Char to handle CP_UTF7 and CP_UTF8's special rules 
    -Change main to mainW to support Unicode archive names
    -Add specific error text for SZ_ERROR_ARCHIVE, SZ_ERROR_NO_ARCHIVE, and SZ_ERROR_PROGRESS
    -Return res on errors instead of always returning 1
@@ -194,8 +195,9 @@ static SRes Utf16_To_Char(CBuf *buf, const UInt16 *s
       {
         const char defaultChar = '_';
         BOOL defUsed;
-        const char *pDefaultChar = (codePage == CP_UTF7 || codePage == CP_UTF8) ? NULL : &defaultChar;
-        BOOL *pDefUsed = pDefaultChar ? NULL : &defUsed;
+        const BOOL codePageIsUtf7Or8 = codePage == CP_UTF7 || codePage == CP_UTF8;
+        const char *pDefaultChar = codePageIsUtf7Or8 ? NULL : &defaultChar;
+        BOOL *pDefUsed = codePageIsUtf7Or8 ? NULL : &defUsed;
         const unsigned numChars = (unsigned)WideCharToMultiByte(
             codePage, 0, (LPCWSTR)s, (int)len, (char *)buf->data, (int)size, pDefaultChar, pDefUsed);
         if (numChars == 0 || numChars >= size)

+ 9 - 1
ISHelp/isetup.xml

@@ -3614,7 +3614,15 @@ Filename: "{win}\MYPROG.INI"; Section: "InstallSettings"; Key: "InstallPath"; St
 <table>
 <tr>
 <td>--key-file=&lt;filename&gt;</td>
-<td>Specifies the private key filename required for signing. This option overriddes the <tt>ISSIGTOOL_KEY_FILE</tt> environment variable which can also be used.</td>
+<td>Specifies the private key filename required for signing. This option overrides the <tt>ISSIGTOOL_KEY_FILE</tt> environment variable which can also be used.</td>
+</tr>
+<tr>
+<td>--quiet, -q</td>
+<td>Suppresses status messages that are normally printed to standard output.</td>
+</tr>
+<tr>
+<td>--help, -?</td>
+<td>Prints usage information.</td>
 </tr>
 </table>
 </indent>

二進制
Projects/Src/Compression.SevenZipDecoder/7zDecode/IS7zDec.obj


+ 1 - 0
whatsnew.htm

@@ -34,6 +34,7 @@ For conditions of distribution and use, see <a href="files/is/license.txt">LICEN
   <li>Compiler IDE change: The editor now restores selections on undo and redo.</li>
   <li>Inno Setup now includes a new command-line tool, ISSigTool.exe. This tool is designed to sign files using ECDSA P-256 cryptographic signatures. Compil32, ISCC, and ISCmplr use these signatures to verify a number of DLL files before loading them.<br />Note: ISSigTool.exe does not replace Microsoft's signtool.exe in any way and is in fact not related to Authenticode Code Signing at all.</li>
   <li><i>Fix:</i> Autocomplete support for parameter names in the <tt>[Components]</tt> and <tt>[Dirs]</tt> sections was broken since 6.1.1.</li>
+  <li><i>Fix:</i> Pascal Scripting support function <tt>Extract7ZipArchive</tt> which was introduced by 6.4.0 would fail with error 11 on older versions of Windows, at least Windows 8.1 and Windows Server 2016.</li>
   <li>Minor tweaks and documentation improvements.</li>
 </ul>