build: Don't include <config.h> in native programs when cross-compiling.
[bpt/guile.git] / libguile / hash.c
index c0a6109..3429310 100644 (file)
@@ -245,7 +245,7 @@ scm_hasher(SCM obj, unsigned long n, size_t d)
             {
               i = len;
               h = n - 1;
-              d2 = (d - 1) / len;
+              d2 = len > 0 ? (d - 1) / len : 0;
             }
 
           while (i--)