cppchecker fixes
This commit is contained in:
@@ -86,7 +86,7 @@ int main(int argc, char **argv) {
|
||||
return 1;
|
||||
}
|
||||
|
||||
nfc3d_amiibo_keys amiiboKeys;
|
||||
nfc3d_amiibo_keys amiiboKeys = {0};
|
||||
if (! LoadAmiikey(amiiboKeys, keyfile))
|
||||
return 5;
|
||||
|
||||
@@ -136,7 +136,7 @@ int main(int argc, char **argv) {
|
||||
return 3;
|
||||
}
|
||||
}
|
||||
size_t readPages = fread(original, 4, NTAG215_SIZE / 4, f);
|
||||
readPages = fread(original, 4, NTAG215_SIZE / 4, f);
|
||||
if (readPages < NFC3D_AMIIBO_SIZE / 4) {
|
||||
fprintf(stderr, "Could not read from save\n");
|
||||
fclose(f);
|
||||
|
||||
@@ -185,7 +185,7 @@ static char *read_string(scanner_t *s, va_list *ap,
|
||||
length = va_arg(*ap, size_t);
|
||||
} else {
|
||||
prev_token(s);
|
||||
length = s->has_error ? 0 : strlen(str);
|
||||
length = s->has_error == 1 ? 0 : strlen(str);
|
||||
}
|
||||
|
||||
if (!s->has_error && strbuffer_append_bytes(&strbuff, str, length) == -1) {
|
||||
|
||||
Reference in New Issue
Block a user