Commit 3dd16b5
committed
Don't call Py_DECREF on null in _ttconv.cpp
Clang's static checker noted that if PyBytes_FromString returns NULL
(presumably rare) then Py_DECREF gets called on NULL; throw an
exception instead. Also assert that the char* inputs are not NULL,
since the Python API functions don't usually check that.1 parent 03e60dc commit 3dd16b5
1 file changed
+10
-6
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
11 | 11 | | |
12 | 12 | | |
13 | 13 | | |
| 14 | + | |
14 | 15 | | |
15 | 16 | | |
16 | 17 | | |
| |||
185 | 186 | | |
186 | 187 | | |
187 | 188 | | |
| 189 | + | |
| 190 | + | |
188 | 191 | | |
189 | | - | |
| 192 | + | |
190 | 193 | | |
191 | | - | |
192 | | - | |
193 | | - | |
194 | | - | |
195 | | - | |
| 194 | + | |
| 195 | + | |
| 196 | + | |
| 197 | + | |
| 198 | + | |
| 199 | + | |
196 | 200 | | |
197 | 201 | | |
198 | 202 | | |
| |||
0 commit comments