Selaa lähdekoodia

core/rand: fix -Wdeprecated-non-prototype

> Warning: core/rand/isaac/rand.c:28:6: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
> void isaac(ctx) randctx *ctx;
>      ^
> Warning: core/rand/isaac/rand.c:81:6: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
> void randinit(ctx, flag) randctx *ctx;

(cherry picked from commit 9475837b209c91366e8bb40416552b02c13aaf3a)
Victor Seva 11 kuukautta sitten
vanhempi
commit
b553882d8d
1 muutettua tiedostoa jossa 2 lisäystä ja 3 poistoa
  1. 2 3
      src/core/rand/isaac/rand.c

+ 2 - 3
src/core/rand/isaac/rand.c

@@ -25,7 +25,7 @@ MODIFIED:
 		*(r++) = b = ind(mm, y >> RANDSIZL) + x; \
 		*(r++) = b = ind(mm, y >> RANDSIZL) + x; \
 	}
 	}
 
 
-void isaac(ctx) randctx *ctx;
+void isaac(randctx *ctx)
 {
 {
 	register ub4 a, b, x, y, *m, *mm, *m2, *r, *mend;
 	register ub4 a, b, x, y, *m, *mm, *m2, *r, *mend;
 	mm = ctx->randmem;
 	mm = ctx->randmem;
@@ -78,8 +78,7 @@ void isaac(ctx) randctx *ctx;
 	}
 	}
 
 
 /* if (flag==TRUE), then use the contents of randrsl[] to initialize mm[]. */
 /* if (flag==TRUE), then use the contents of randrsl[] to initialize mm[]. */
-void randinit(ctx, flag) randctx *ctx;
-word flag;
+void randinit(randctx *ctx, word flag)
 {
 {
 	word i;
 	word i;
 	ub4 a, b, c, d, e, f, g, h;
 	ub4 a, b, c, d, e, f, g, h;