[Scummvm-git-logs] scummvm master -> daffdcea1aa6ddbb8a0212f31626e7d47e5769b9

dreammaster paulfgilbert at gmail.com
Sun Apr 14 17:59:47 CEST 2019


This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .

Summary:
daffdcea1a GLK: Fix compiler warnings for dispatch layer


Commit: daffdcea1aa6ddbb8a0212f31626e7d47e5769b9
    https://github.com/scummvm/scummvm/commit/daffdcea1aa6ddbb8a0212f31626e7d47e5769b9
Author: Paul Gilbert (dreammaster at scummvm.org)
Date: 2019-04-14T08:59:39-07:00

Commit Message:
GLK: Fix compiler warnings for dispatch layer

Changed paths:
    engines/glk/glk_dispa.cpp
    engines/glk/glk_types.h


diff --git a/engines/glk/glk_dispa.cpp b/engines/glk/glk_dispa.cpp
index cb6dc8d..63d9333 100644
--- a/engines/glk/glk_dispa.cpp
+++ b/engines/glk/glk_dispa.cpp
@@ -340,7 +340,7 @@ uint32 GlkAPI::gidispatch_count_classes() const {
 }
 
 const gidispatch_intconst_t *GlkAPI::gidispatch_get_class(uint32 index) const {
-    if (index < 0 || index >= NUMCLASSES)
+    if (index >= NUMCLASSES)
         return nullptr;
     return &(class_table[index]);
 }
@@ -350,7 +350,7 @@ uint32 GlkAPI::gidispatch_count_intconst() const {
 }
 
 const gidispatch_intconst_t *GlkAPI::gidispatch_get_intconst(uint32 index) const {
-    if (index < 0 || index >= NUMINTCONSTANTS)
+    if (index >= NUMINTCONSTANTS)
         return nullptr;
     return &(intconstant_table[index]);
 }
@@ -360,7 +360,7 @@ uint32 GlkAPI::gidispatch_count_functions() const {
 }
 
 gidispatch_function_t *GlkAPI::gidispatch_get_function(uint32 index) const {
-    if (index < 0 || index >= NUMFUNCTIONS)
+    if (index >= NUMFUNCTIONS)
         return nullptr;
     return &(function_table[index]);
 }
diff --git a/engines/glk/glk_types.h b/engines/glk/glk_types.h
index 5058698..8778362 100644
--- a/engines/glk/glk_types.h
+++ b/engines/glk/glk_types.h
@@ -224,7 +224,7 @@ union gidispatch_rock_t {
 };
 
 union gluniversal_union {
-	uint32 uint;        ///< Iu
+	uint uint;          ///< Iu
 	int32 sint;         ///< Is
 	void *opaqueref;    ///< Qa, Qb, Qc...
 	byte uch;           ///< Cu





More information about the Scummvm-git-logs mailing list