shell32: Simplify check for empty string (PVS-Studio)

Alistair Leslie-Hughes leslie_alistair at hotmail.com
Fri Nov 7 04:03:38 CST 2014


On 07/11/14 20:22, Michael Stefaniuc wrote:
> ---
>   dlls/shell32/shellord.c        |  2 +-
>   dlls/shell32/tests/ebrowser.c  |  2 +-
>   dlls/shell32/tests/shlfolder.c | 14 +++++++-------
>   3 files changed, 9 insertions(+), 9 deletions(-)
>
> diff --git a/dlls/shell32/shellord.c b/dlls/shell32/shellord.c
> index 56c9fe9..914dc5a 100644
> --- a/dlls/shell32/shellord.c
> +++ b/dlls/shell32/shellord.c
> @@ -947,7 +947,7 @@ void WINAPI SHAddToRecentDocs (UINT uFlags,LPCVOID pv)
>   		/* buffer size looks good */
>   		ptr += 12; /* get to string */
>   		len = bufused - (ptr-buffer);  /* get length of buf remaining */
> -		if ((lstrlenA(ptr) > 0) && (lstrlenA(ptr) <= len-1)) {
> +                if (ptr[0] && (lstrlenA(ptr) <= len-1)) {
You are changing tabs to spaces here.

Best Regards
Alistair Leslie-Hughes



More information about the wine-devel mailing list