dlls/fusion/assembly.c -- no-op error checks

Gerald Pfeifer gerald at pfeifer.com
Wed Apr 16 09:28:24 CDT 2008


Both offset and tables[].offset are of unsigned types, so these two
checks for errors will never trigger.

Gerald

ChangeLog:
Remove two no-op error checks in assembly_get_name() and 
assembly_get_pubkey_token().

Index: dlls/fusion/assembly.c
===================================================================
RCS file: /home/wine/wine/dlls/fusion/assembly.c,v
retrieving revision 1.1
diff -u -3 -p -r1.1 assembly.c
--- dlls/fusion/assembly.c	15 Apr 2008 13:49:39 -0000	1.1
+++ dlls/fusion/assembly.c	16 Apr 2008 14:26:51 -0000
@@ -404,8 +404,6 @@ HRESULT assembly_get_name(ASSEMBLY *asse
     ULONG offset;
 
     offset = assembly->tables[0x20].offset; /* FIXME: add constants */
-    if (offset < 0)
-        return E_FAIL;
 
     asmtbl = (ASSEMBLYTABLE *)assembly_data_offset(assembly, offset);
     if (!asmtbl)
@@ -515,8 +513,6 @@ HRESULT assembly_get_pubkey_token(ASSEMB
     *token = NULL;
 
     offset = assembly->tables[0x20].offset; /* FIXME: add constants */
-    if (offset < 0)
-        return E_FAIL;
 
     asmtbl = (ASSEMBLYTABLE *)assembly_data_offset(assembly, offset);
     if (!asmtbl)



More information about the wine-patches mailing list