mirror of
https://github.com/EsotericSoftware/spine-runtimes.git
synced 2025-12-22 18:26:12 +08:00
[c] Ignore unused result from fread (#1644)
src/spine/extension.c:95:2: warning: ignoring return value of ‘fread’, declared with attribute warn_unused_result [-Wunused-result]
95 | fread(data, 1, *length, file);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
This commit is contained in:
parent
b44154e2b7
commit
c0f101969d
@ -92,7 +92,8 @@ char* _spReadFile (const char* path, int* length) {
|
|||||||
fseek(file, 0, SEEK_SET);
|
fseek(file, 0, SEEK_SET);
|
||||||
|
|
||||||
data = MALLOC(char, *length);
|
data = MALLOC(char, *length);
|
||||||
fread(data, 1, *length, file);
|
size_t result = fread(data, 1, *length, file);
|
||||||
|
UNUSED(result);
|
||||||
fclose(file);
|
fclose(file);
|
||||||
|
|
||||||
return data;
|
return data;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user