Prefer "sizeof v" over the equivalent "4".
[pspp] / lib / sha1.c
index 22172a950d15921cd603240b12d7623e5c7eaa5f..8869d43ffb1a0147f044afed664a45928e2cc619 100644 (file)
@@ -73,7 +73,7 @@ sha1_init_ctx (struct sha1_ctx *ctx)
 static void
 set_uint32 (char *cp, uint32_t v)
 {
-  memcpy (cp, &v, 4);
+  memcpy (cp, &v, sizeof v);
 }
 
 /* Put result from CTX in first 20 bytes following RESBUF.  The result