Message283777
The following code snippet:
----------------------------------------------
#include <stdio.h>
#include <Python.h>
int main()
{
char *broken_string[8];
char broken_char = 4294967252;
sprintf(broken_string, "%c", broken_char);
PyUnicode_FromString(broken_string);
}
----------------------------------------------
Produces a Segmentation Fault.
Is this behaviour the expected one?
The real life example comes when reading a malformed path on a Ext4 filesystem. The read string causes PyUnicode_FromString to segfault. |
|
Date |
User |
Action |
Args |
2016-12-21 19:52:12 | noxdafox | set | recipients:
+ noxdafox |
2016-12-21 19:52:12 | noxdafox | set | messageid: <1482349932.8.0.094002567537.issue29039@psf.upfronthosting.co.za> |
2016-12-21 19:52:12 | noxdafox | link | issue29039 messages |
2016-12-21 19:52:12 | noxdafox | create | |
|