-
-
Notifications
You must be signed in to change notification settings - Fork 573
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
segfault on Gentoo #902
Comments
I am clearly not enough of a linux pro for this. on my ubuntu box for dummies everything seems to works. did you try with the stock libgit2 1.2.0? also can you run it in a debugger so we get a useful callstack where it crashes? @dm9pZCAq also I am curious: what added value the issue description "yet another" had? |
can you recommend some useful tools for rust debugging?
because that's "yet another" weird segfault on Gentoo (first is here #459) |
ok, with best debug tool (putting Line 105 in 7dd6b4e
after i commented it out, everything works fine |
for me, this causes segfault too #include <stdio.h>
#include <git2/trace.h>
void
callback(git_trace_level_t level, const char *msg)
{
puts(msg);
}
int
main(void)
{
printf("%d\n", git_trace_set(GIT_TRACE_TRACE, callback));
return 0;
} i'll go figure it out... |
ok, i figured out... the problem was that i compiled
maybe it would be better to add |
afaik tracing is on by default. so yeah maybe a note in the readme to mention that we require this to be enabled would make sense |
on most distros yes, but on Gentoo you have choice what to use and this is not enabled by default |
this is how i did it: it can be enabled by default, but have this choice will be cool ?
///
#[cfg(feature = "trace-libgit")]
pub fn register_tracing_logging() -> bool {
fn git_trace(level: git2::TraceLevel, msg: &str) {
log::info!("[{:?}]: {}", level, msg);
}
git2::trace_set(git2::TraceLevel::Trace, git_trace)
}
///
#[cfg(not(feature = "trace-libgit"))]
pub fn register_tracing_logging() -> bool {
true
} and add feature to |
@dm9pZCAq I gladly accept a PR for this 👍 |
Describe the bug
segfault when running
gitui
To Reproduce
Steps to reproduce the behavior:
run
gitui
on eny directoryContext (please complete the following information):
0.17.1
1.54.0
1.2.0
with remote: Markgit_remote_name_is_valid
asGIT_EXTERN
libgit2/libgit2#6032 applied1.1.1l
1.2.2
Additional context
with
gitui-0.16.2
everything works fine, but with same ebuild but for0.17.1
after successful build, it's segfaults at runtimefirstly i was think this is because of
git_branch name is_valid
but my tests compiles and runs fineC
out:
lddtree
:rust
out:
lddtree
:strace gitui
maybe you know what it could be?
The text was updated successfully, but these errors were encountered: