Michael Stefaniuc : ntdll: Don' t use HIWORD to check if an atom is a small int.

Alexandre Julliard julliard at winehq.org
Mon Sep 5 13:26:21 CDT 2011


Module: wine
Branch: master
Commit: 5a886316b4575b2ee2dae5b556c5891d22b17dd7
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=5a886316b4575b2ee2dae5b556c5891d22b17dd7

Author: Michael Stefaniuc <mstefani at redhat.de>
Date:   Mon Sep  5 11:18:17 2011 +0200

ntdll: Don't use HIWORD to check if an atom is a small int.

---

 dlls/ntdll/atom.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/dlls/ntdll/atom.c b/dlls/ntdll/atom.c
index 8ac4b97..3789567 100644
--- a/dlls/ntdll/atom.c
+++ b/dlls/ntdll/atom.c
@@ -212,7 +212,7 @@ NTSTATUS WINAPI RtlAddAtomToAtomTable( RTL_ATOM_TABLE table, const WCHAR* name,
     if (!table) status = STATUS_INVALID_PARAMETER;
     else
     {
-        size_t len = HIWORD(name) ? strlenW(name) : 0;
+        size_t len = IS_INTATOM(name) ?  0 : strlenW(name);
         status = is_integral_atom( name, len, atom );
         if (status == STATUS_MORE_ENTRIES)
         {
@@ -242,7 +242,7 @@ NTSTATUS WINAPI RtlLookupAtomInAtomTable( RTL_ATOM_TABLE table, const WCHAR* nam
     if (!table) status = STATUS_INVALID_PARAMETER;
     else
     {
-        size_t len = HIWORD(name) ? strlenW(name) : 0;
+        size_t len = IS_INTATOM(name) ? 0 : strlenW(name);
         status = is_integral_atom( name, len, atom );
         if (status == STATUS_MORE_ENTRIES)
         {




More information about the wine-cvs mailing list