Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:Step:15-SP2
fonttosfnt
0023-Fail-if-ftell-fails.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File 0023-Fail-if-ftell-fails.patch of Package fonttosfnt
From 49524b5db4867b5e896ed299fd66b390e68f1ffc Mon Sep 17 00:00:00 2001 From: Peter Hutterer <peter.hutterer@who-t.net> Date: Tue, 25 May 2021 09:50:45 +1000 Subject: [PATCH] Fail if ftell fails Fixes a coverity warning: ftell may return -1 on error which we then pass into fseek later. We properly fail there anyway, so this change is unlikely to have any real effect. --- write.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/write.c b/write.c index e68b70c..d86ce5f 100644 --- a/write.c +++ b/write.c @@ -758,6 +758,10 @@ writeEBLC(FILE* out, FontPtr font) int offset; location = ftell(out); + if (location == -1) { + perror("Couldn't ftell"); + return -1; + } rc = fseek(out, table->location + 4, SEEK_SET); if(rc != 0) { perror("Couldn't seek"); -- GitLab
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor