Commit c24be24
tracing: Fix possible memory leak in __create_synth_event() error path
There's error paths in __create_synth_event() after the argv is allocated
that fail to free it. Add a jump to free it when necessary.
Link: https://lkml.kernel.org/r/20211209024317.11783-1-linmq006@gmail.com
Suggested-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
Signed-off-by: Miaoqian Lin <linmq006@gmail.com>
[ Fixed up the patch and change log ]
Signed-off-by: Steven Rostedt (VMware) <rostedt@goodmis.org>1 parent e1067a0 commit c24be24
1 file changed
Lines changed: 6 additions & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1237 | 1237 | | |
1238 | 1238 | | |
1239 | 1239 | | |
1240 | | - | |
1241 | 1240 | | |
1242 | | - | |
| 1241 | + | |
1243 | 1242 | | |
1244 | 1243 | | |
1245 | 1244 | | |
| |||
1262 | 1261 | | |
1263 | 1262 | | |
1264 | 1263 | | |
1265 | | - | |
| 1264 | + | |
1266 | 1265 | | |
1267 | 1266 | | |
1268 | 1267 | | |
1269 | 1268 | | |
1270 | 1269 | | |
1271 | 1270 | | |
1272 | | - | |
| 1271 | + | |
1273 | 1272 | | |
1274 | 1273 | | |
1275 | 1274 | | |
1276 | 1275 | | |
| 1276 | + | |
1277 | 1277 | | |
1278 | 1278 | | |
1279 | 1279 | | |
1280 | 1280 | | |
1281 | 1281 | | |
1282 | 1282 | | |
1283 | 1283 | | |
1284 | | - | |
1285 | 1284 | | |
1286 | 1285 | | |
1287 | 1286 | | |
| |||
1307 | 1306 | | |
1308 | 1307 | | |
1309 | 1308 | | |
| 1309 | + | |
| 1310 | + | |
1310 | 1311 | | |
1311 | 1312 | | |
1312 | 1313 | | |
| |||
0 commit comments