| 4377 | } |
| 4378 | |
| 4379 | static int stbi__jpeg_test(stbi__context* s) { |
| 4380 | int r; |
| 4381 | stbi__jpeg* j = (stbi__jpeg*)stbi__malloc(sizeof(stbi__jpeg)); |
| 4382 | if (!j) |
| 4383 | return stbi__err("outofmem", "Out of memory"); |
| 4384 | j->s = s; |
| 4385 | stbi__setup_jpeg(j); |
| 4386 | r = stbi__decode_jpeg_header(j, STBI__SCAN_type); |
| 4387 | stbi__rewind(s); |
| 4388 | STBI_FREE(j); |
| 4389 | return r; |
| 4390 | } |
| 4391 | |
| 4392 | static int stbi__jpeg_info_raw(stbi__jpeg* j, int* x, int* y, int* comp) { |
| 4393 | if (!stbi__decode_jpeg_header(j, STBI__SCAN_header)) { |
no test coverage detected