Skip to content

dev#273

Merged
Asherda merged 23 commits intomasterfrom
dev
Jan 14, 2020
Merged

dev#273
Asherda merged 23 commits intomasterfrom
dev

Conversation

@Asherda
Copy link
Copy Markdown

@Asherda Asherda commented Jan 14, 2020

No description provided.

@Asherda Asherda merged commit 68b2bea into master Jan 14, 2020
Asherda pushed a commit to Asherda/VerusCoin that referenced this pull request Mar 11, 2024
Sync backports and checkpoint additions
@DeckerSU
Copy link
Copy Markdown

I guess this behavior is wrong:

size_t fread_size = fread(seed, 1, 32, f);
fclose(f);
if (fread_size == 0) {
return 1;

We are trying to read 32 bytes and returning error if fread_size == 0, but actually we should return error in any case if we don't read exactly 32 bytes, like this:

https://github.com/DeckerSU/KomodoOcean/blob/37b086f98d87be8aa727efd1fae03cbada6c8f38/src/cryptoconditions/src/include/ed25519/src/seed.c#L33-L36

    const size_t items_read = fread(seed, 1, 32, f);
    fclose(f);
    if (items_read != 32)
        return 1;

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants