martijnvanbrummelen / nwipe

nwipe secure disk eraser
GNU General Public License v2.0
797 stars 86 forks source link

fix type error on i686 #579

Closed xambroz closed 3 months ago

xambroz commented 6 months ago

This fixes the type error on i686 when compiling with gcc 14. Mentioned in bug report #578

Knogle commented 6 months ago

Ahoy. Please run make format, and commit again :)

PartialVolume commented 3 months ago

@xambroz Hi, I would like to merge this however it needs the following change made

diff --git a/src/prng.c b/src/prng.c
index facef65..abf1b6c 100644
--- a/src/prng.c
+++ b/src/prng.c
@@ -284,8 +284,7 @@ int nwipe_xoroshiro256_prng_init( NWIPE_PRNG_INIT_SIGNATURE )
         /* This is the first time that we have been called. */
         *state = malloc( sizeof( xoroshiro256_state_t ) );
     }
-    xoroshiro256_init(
-        (xoroshiro256_state_t*) *state, (uint64_t*) ( seed->s ), seed->length / sizeof( uint64_t ) );
+    xoroshiro256_init( (xoroshiro256_state_t*) *state, (uint64_t*) ( seed->s ), seed->length / sizeof( uint64_t ) );

     return 0;
 }
make: *** [Makefile:797: check-format] Error 1

As @knogle mentioned, you just need to run make format and commit the change so ci_formatting will pass.

I did try to do a PR on patch-5 but can't seem to do that without deleting my own fork of nwipe

Knogle commented 3 months ago

@PartialVolume did you try to do it in a new branch? Otherwise i could submit the fixed PR for this.

PartialVolume commented 3 months ago

Merged #588

PartialVolume commented 3 months ago

Closing as this fix was included in #588