Title: syslog issues · Issue #95041 · python/cpython · GitHub
Open Graph Title: syslog issues · Issue #95041 · python/cpython
X Title: syslog issues · Issue #95041 · python/cpython
Description: There are several issues with corner cases in syslog.openlog(). syslog_get_argv() swallows exceptions, but not in all cases. if ident is non UTF-8 encodable, syslog.openlog() fails after setting the global reference to ident. Now the C s...
Open Graph Description: There are several issues with corner cases in syslog.openlog(). syslog_get_argv() swallows exceptions, but not in all cases. if ident is non UTF-8 encodable, syslog.openlog() fails after setting th...
X Description: There are several issues with corner cases in syslog.openlog(). syslog_get_argv() swallows exceptions, but not in all cases. if ident is non UTF-8 encodable, syslog.openlog() fails after setting th...
Opengraph URL: https://github.com/python/cpython/issues/95041
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"syslog issues","articleBody":"There are several issues with corner cases in `syslog.openlog()`.\r\n\r\n* `syslog_get_argv()` swallows exceptions, but not in all cases.\r\n* if `ident` is non UTF-8 encodable, `syslog.openlog()` fails after setting the global reference to `ident`. Now the C string saved internally in the previous call to `openlog()` points to the freed memory.\r\n* `PySys_Audit()` can crash if `ident` is NULL.\r\n* There may be a race condition with `syslog.syslog()`, because the global reference to `ident` is decrefed before setting the new value.\r\n\r\nAnd, since `syslog.syslog()` releases the GIL, there may be a race condition `syslog.syslog()` with `syslog.openlog()` and `syslog.closelog()` which can decref the global reference to `ident`.\r\n\r\nP.S. @noamcohen97 noticed yet one issue in `syslog.syslog()` (potential returning a value from a function while an exception is set https://github.com/python/cpython/pull/95012#discussion_r929558676) and fixed it.","author":{"url":"https://github.com/serhiy-storchaka","@type":"Person","name":"serhiy-storchaka"},"datePublished":"2022-07-20T07:12:55.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":6},"url":"https://github.com/95041/cpython/issues/95041"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:cb42abaa-8922-9b1b-5e71-c403b5840e5b |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | A788:28656B:5D9EA6:820D4E:696A260D |
| html-safe-nonce | 0c51feb568264f6273f39af95ebd75f27e13628b13664f651740634b7eb44e18 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBNzg4OjI4NjU2Qjo1RDlFQTY6ODIwRDRFOjY5NkEyNjBEIiwidmlzaXRvcl9pZCI6Ijg0NDI2MTA0MTIyODc1NjczNzMiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | 57be510dc0c8eb86326df0372fffe771cc51adff06ce8b3d78f077d4162ac218 |
| hovercard-subject-tag | issue:1310555831 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/python/cpython/95041/issue_layout |
| twitter:image | https://opengraph.githubassets.com/91ad92365127451fa7beed4275fdf4825994354c7c17d0d3a24ce05283a7dfed/python/cpython/issues/95041 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/91ad92365127451fa7beed4275fdf4825994354c7c17d0d3a24ce05283a7dfed/python/cpython/issues/95041 |
| og:image:alt | There are several issues with corner cases in syslog.openlog(). syslog_get_argv() swallows exceptions, but not in all cases. if ident is non UTF-8 encodable, syslog.openlog() fails after setting th... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | serhiy-storchaka |
| hostname | github.com |
| expected-hostname | github.com |
| None | a1022f03e4f0d91ea173e4e5dac892c982e0588c62f1ce56121d755a320a3569 |
| turbo-cache-control | no-preview |
| go-import | github.com/python/cpython git https://github.com/python/cpython.git |
| octolytics-dimension-user_id | 1525981 |
| octolytics-dimension-user_login | python |
| octolytics-dimension-repository_id | 81598961 |
| octolytics-dimension-repository_nwo | python/cpython |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 81598961 |
| octolytics-dimension-repository_network_root_nwo | python/cpython |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | f472b8e6c7b3fdd5d0354972a3f4c516289bf0be |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width