From e3de4fd2ef5465b8b48fe4ab136639e037347093 Mon Sep 17 00:00:00 2001 From: jl777 Date: Sat, 2 Mar 2019 20:06:11 -1100 Subject: [PATCH] +print --- src/cc/dilithium.c | 19 ++++++++++++++++++- src/cc/rogue/rogue.c | 8 ++++---- 2 files changed, 22 insertions(+), 5 deletions(-) diff --git a/src/cc/dilithium.c b/src/cc/dilithium.c index eb2b78ecc..f646b53c4 100644 --- a/src/cc/dilithium.c +++ b/src/cc/dilithium.c @@ -2940,11 +2940,17 @@ int32_t dilithium_Qmsghash(uint8_t *msg,CTransaction tx,std::vector vou { vintxids.push_back(tx.vin[i].prevout.hash); vinprevns.push_back(tx.vin[i].prevout.n); + fprintf(stderr,"%s/v%d ",tx.vin[i].prevout.hash.GetHex().c_str(),tx.vin[i].prevout.n); } for (i=0; iInvalid("failed dilithium verify"); else if ( mlen != 32 || memcmp(msg,msg2,32) != 0 ) + { + for (i=0; i<32; i++) + fprintf(stderr,"%02x",msg[i]); + fprintf(stderr," vs "); + for (i=0; iInvalid("failed dilithium msg verify"); + } else return true; } } else return eval->Invalid("failed decode Qsend"); diff --git a/src/cc/rogue/rogue.c b/src/cc/rogue/rogue.c index 8406684c7..ca0c92343 100644 --- a/src/cc/rogue/rogue.c +++ b/src/cc/rogue/rogue.c @@ -131,21 +131,21 @@ int32_t flushkeystrokes_local(struct rogue_state *rs,int32_t waitflag) rs->num = 0; retflag = 0; fclose(fp); - if ( (fp= fopen("savefile","wb")) != 0 ) + /*if ( (fp= fopen("savefile","wb")) != 0 ) { - //save_file(rs,fp,0); + save_file(rs,fp,0); if ( 0 && (fp= fopen("savefile","rb")) != 0 ) { for (i=0; i<0x150; i++) fprintf(stderr,"%02x",fgetc(fp)); fprintf(stderr," first part rnd.%d\n",rnd(1000)); fclose(fp); - } + }*/ roguefname(fname,rs->seed,rs->counter+1); if ( (fp= fopen(fname,"wb")) != 0 ) // truncate next file fclose(fp); //fprintf(stderr,"savefile <- %s retflag.%d\n",fname,retflag); - } + //} } else fprintf(stderr,"error writing (%s)\n",fname); } else fprintf(stderr,"error creating (%s)\n",fname); return(retflag);