Message338361
| Author | vstinner |
|---|
| Recipients | vstinner |
|---|
| Date | 2019-03-19.14:57:37 |
|---|
| SpamBayes Score | -1.0 |
|---|
| Marked as misclassified | Yes |
|---|
| Message-id | <1553007457.48.0.128688870738.issue36365@roundup.psfhosted.org> |
|---|
| In-reply-to | |
|---|
| Content |
|---|
Warning seen on Fedora 29 with GCC 8.3.1 20190223 (Red Hat 8.3.1-2):Objects/structseq.c: In function 'structseq_repr':Objects/structseq.c:187:5: warning: 'strncpy' specified bound depends on the length of the source argument [-Wstringop-overflow=] strncpy(pbuf, typ->tp_name, len); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~Objects/structseq.c:185:11: note: length computed here len = strlen(typ->tp_name) > TYPE_MAXSIZE ? TYPE_MAXSIZE : ^~~~~~~~~~~~~~~~~~~~Attached PR rewrites structseq_repr() using _PyUnicodeWriter for better performance and remove the arbitrary limit of 512 bytes. |
| History |
|---|
| Date | User | Action | Args |
|---|
| 2019-03-19 14:57:37 | vstinner | set | recipients: +vstinner | | 2019-03-19 14:57:37 | vstinner | set | messageid: <1553007457.48.0.128688870738.issue36365@roundup.psfhosted.org> | | 2019-03-19 14:57:37 | vstinner | link | issue36365 messages | | 2019-03-19 14:57:37 | vstinner | create | |
|