sourcestats: fix signedness in scanf format
This commit is contained in:
parent
9479c6451e
commit
0b71504ee9
1 changed files with 2 additions and 1 deletions
|
@ -771,7 +771,8 @@ SST_LoadFromFile(SST_Stats inst, FILE *in)
|
|||
double weight;
|
||||
|
||||
if (fgets(line, sizeof(line), in) &&
|
||||
(sscanf(line, "%u", &inst->n_samples) == 1) && inst->n_samples <= MAX_SAMPLES) {
|
||||
sscanf(line, "%d", &inst->n_samples) == 1 &&
|
||||
inst->n_samples > 0 && inst->n_samples <= MAX_SAMPLES) {
|
||||
|
||||
line_number = 2;
|
||||
|
||||
|
|
Loading…
Reference in a new issue