8000 Initialize offset to zero in FT2Font::make_open_args · jdgd1/matplotlib@3380256 · GitHub
[go: up one dir, main page]

Skip to content

Commit 3380256

Browse files
committed
Initialize offset to zero in FT2Font::make_open_args
Clang warns that it gets a garbage value on Python 2, since mpl_PyFile_Dup expands to a function call that does not use &offset. It seems that the value is not used on Python 2 but it doesn't cost much to silence the warning.
1 parent 03e60dc commit 3380256

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/ft2font.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2165,7 +2165,7 @@ FT2Font::make_open_args(PyObject *py_file_arg, FT_Open_Args *open_args)
21652165
py_file_def *stream_info = NULL;
21662166
long file_size;
21672167
FT_Byte *new_memory;
2168-
mpl_off_t offset;
2168+
mpl_off_t offset = 0;
21692169

21702170
int result = -1;
21712171

0 commit comments

Comments
 (0)
0