Commit a5f95c2b3c9de5ba46c8f591ed00507b4f05a8e8

Ran Benita 2019-11-09T11:33:45

atom: use explicit size for fingerprint Signed-off-by: Ran Benita <ran@unusedvar.com>

diff --git a/src/atom.c b/src/atom.c
index 2b5b3ed..2ef7c85 100644
--- a/src/atom.c
+++ b/src/atom.c
@@ -75,7 +75,7 @@
 
 struct atom_node {
     xkb_atom_t left, right;
-    unsigned int fingerprint;
+    uint32_t fingerprint;
     char *string;
 };
 
@@ -125,10 +125,10 @@ atom_text(struct atom_table *table, xkb_atom_t atom)
 
 static bool
 find_atom_pointer(struct atom_table *table, const char *string, size_t len,
-                  xkb_atom_t **atomp_out, unsigned int *fingerprint_out)
+                  xkb_atom_t **atomp_out, uint32_t *fingerprint_out)
 {
     xkb_atom_t *atomp = &table->root;
-    unsigned int fingerprint = 0;
+    uint32_t fingerprint = 0;
     bool found = false;
 
     for (size_t i = 0; i < (len + 1) / 2; i++) {
@@ -187,7 +187,7 @@ atom_intern(struct atom_table *table, const char *string, size_t len)
 {
     xkb_atom_t *atomp;
     struct atom_node node;
-    unsigned int fingerprint;
+    uint32_t fingerprint;
 
     if (!string)
         return XKB_ATOM_NONE;