- Zoom factor is unsigned.
- It is comprised between 1 and 9, other values are invalid.
- Check for value validity when reading the zoom string from the combo-list.
Fixes GCC 8 warning:
base/applications/network/telnet/src/tnmain.cpp:171:8: error: this 'for' clause does not guard... [-Werror=misleading-indentation]
for (j = cursor; j >= 0; j--)
^~~
base/applications/network/telnet/src/tnmain.cpp:174:9: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the 'for'
for (k = --j; k >= 0; k--)
^~~
Fixes GCC 8 warning:
base/applications/network/telnet/src/tmapldr.cpp:70:3: error: this 'while' clause does not guard... [-Werror=misleading-indentation]
while (buf[len])
^~~~~
base/applications/network/telnet/src/tmapldr.cpp:74:4: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the 'while'
if (len && (buf[len-1] == ' ')) {
^~
Fixes GCC 8 warning:
base/applications/network/telnet/src/tnmain.cpp:171:8: error: this 'for' clause does not guard... [-Werror=misleading-indentation]
for (j = cursor; j >= 0; j--)
^~~
base/applications/network/telnet/src/tnmain.cpp:174:9: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the 'for'
for (k = --j; k >= 0; k--)
^~~
- Only include the strictly necessary headers.
- Get rid of the dependency on shell and user DLLs.
- fgetws() gets the string buffer size in number of characters.
- We can use the CRT functions for lengths of the arguments etc.
- The cFileName member of the WIN32_FIND_DATAW structure does not
contain the full PATH to the enumerated file, but only its name.
In order to use _wfopen(), build a full file path out of the
directory part of the file specification and the full file name.
- Simplify a ConPrintf() call to make it "atomic".
- Fix the "confusion" lLineCount vs. lLineNumber vocable in the code.
- Do not emit an extra newline after having displayed the results for
a given file.
- Uppercase the switches for performing the comparisons.
- Send the errors to the StdErr stream.
- Remove trailing whitespace.
This commit contains a complete rewrite of find console utility.
The goal of it was to make the source code easier to maintain
and to add a missing feature (/offline switch).
Additional changes:
* now the program operates on Unicode strings;
* added conutils and shlwapi as program's libraries;
* added IDS_INVALID_SWITCH string into resources;
* modified IDS_USAGE string to include /offline switch
description.
https://ss64.com/nt/find.html was used for reference.
This is also done on Windows for backwards compatibility with Windows 3.x/9x.
But, it's also used (i.e. "required") by some installers, like Doom 3 Demo installer and Battlefield 1942 Single Player Demo installer, for successful opening of their Readme file at the end of their installation!
Our On-Screen Keyboard has a manifest and the buttons (the ones with BS_ICON styles) aren't rendered with the specific theme as it should be but instead it takes the classic theme.
The code relies on NM_CUSTOMDRAW notification, which is more intuitive and efficient than doing owner-drawn operations as NM_CUSTOMDRAW allows the controls to use styles whereas you cannot do it on owner-drawn controls.
CORE-15965