Till
Anonymous
Till
It's not code
Vlad
It isn't code
Till
Yes
Vlad
It's some bs from the terminal, kek
Till
@unterumarmung I feel tired about man's screenshots
Vlad
And what it is supposed to do?
Anonymous
@waldo336
Please share code via paste.ubuntu.com
Vlad
How?) Synchronized methods are too mainstream I guess.
Vlad
Or mutexes for that matter
Till
Wtf, I don't want download files on my perfect device
Till
Sorry, but I don't know JNI 😒, I really want help you, but I can't, oh sorry
olli
potential race condition? given the code I can't reproduce your issue
Anonymous
Vlad
Hope he's gonna get it))
Vlad
Vlad
This error could be anything really. But what it says is that you do smth like this:
int& getInt()
{
int a;
.... // some actions with a
return a; // UB because you wiil access a variable with ended lifetime
}
Vlad
You know it's easy to check. What if you will not get errors with locks?
Vlad
std::mutex jni_mut;
....
void callNative()
{
// synchronized call
{
std::lock_guard<std::mutex> lock(jni_mut);
jmethodID methodID = env->GetMethodID(surfaceClass, "mWTBStart", "()V");
if (methodID == nullptr) return;
env->CallVoidMethod(surfaceObject, methodID);
}
}
Vlad
Formatting got funky but you got the point
Till
Vlad
Vlad
Is it your class?
Vlad
If so then make a gd operator
Vlad
Oh you're trying to copy a mutex?
Till
It's seem like you try copy mutex, incredible
Vlad
Vlad
Also are you sure that mutex should be in an object?
Vlad
I guess what it says that you must be attached also
Vlad
Also get rid of deleted local reference abuse
Till
Object was destroyed before👍
Till
Yeah, pls watch life time of yours objects
Vlad
How does creating an object makes you use a deleted reference?
Till
I can't recognize text on photo, sorry, but I don't read it
Till
It's another text ...
Vlad
It says that it couldn't find your gd class. Doncha see?
Till
Just rewrite code
Vlad
Till
You need to pay attention to lifetime objects
Till
I think we can't help you enough
Till
Just debugging help you
Vlad
printf"s for the rescue
四只老虎化黃油
Is it important for a c++ programmer to know how to use gdb?
Vlad
"Whatever bs that outputs to the console"
四只老虎化黃油
V01D
I spent 10 min trying to fix a compile error, turns out I missed the semicolon for the function declarition in the header file. Sucks to suck 😂
Anonymous
I feel you😂😂
V01D
And all gcc says is: use a '=', ':', ';', or attribute before void main - Like REALLY?
klimi
Cool?
klimi
I just like the document structure...
Accel
Vlad
What's that?
Accel
export module nice
四只老虎化黃油
After overloading operator + for a class, do we automatically get operator += working?
Vlad
四只老虎化黃油
get it, thanks!
Vlad
Thx for clarifying
Vlad
So it was yours user code fault after all?
Dima
lol
Xam
ZZ ‘BG ZZ🥱🥱🤓1n'21'221kh k'2h
Anonymous
Anonymous
Anonymous
Anonymous
Anonymous
Anonymous
Anonymous
Anonymous
Anonymous
Anonymous
Anonymous
Anonymous
Anonymous
Anonymous