watchdog: SEGFAULT on macOS with the latest version of watchdog
Unfortunately, this will be tough to describe, since I don’t have a mac and only my CI is complaining.
I’m using watchdog as a submodule and today tried to update it. One specific test consistently makes pytest segfault.
This is the log from a SEGFAULTING run: https://dev.azure.com/borisstaletic/3ce92110-caa5-4c49-b8c3-44a433da676b/_apis/build/builds/1535/logs/64 The way I’m using watchdog is by talking to, in this case, jdt.ls. When I open this file it sends… these patterns:
[
{
"globPattern": "**/*.java"
},
{
"globPattern": "**/.project"
},
{
"globPattern": "**/.classpath"
},
{
"globPattern": "**/.settings/*.prefs"
},
{
"globPattern": "**/src/**"
},
{
"globPattern": "**/*.gradle"
},
{
"globPattern": "**/gradle.properties"
},
{
"globPattern": "**/pom.xml"
},
{
"globPattern": "/home/bstaletic/work/ycmd/ycmd/tests/java/testdata/simple_eclipse_project",
"kind": 4
}
]
Which we then edit, like this: https://github.com/ycm-core/ycmd/blob/master/ycmd/completers/language_server/language_server_completer.py#L590-L591
And finally use that with this handler: https://github.com/ycm-core/ycmd/blob/master/ycmd/completers/language_server/language_server_completer.py#L3219
Any further information, as well as running the CI, I can gladly provide.
About this issue
- Original URL
- State: closed
- Created 3 years ago
- Comments: 17 (9 by maintainers)
@puremourning, this is very helpful, thanks! It also explains why the segfault didn’t show up in our testing: the code block which you show is only called as a backup when
CFStringGetCStringPtr
returns NULL. I suspect that the string length is incorrectly calculated there.Could you try applying this patch and see if it fixes the problem: