Running A Profiled App on X86_64 Android Emulator Qt6.9.1
-
@SMF-Qt
But your code shows you usingexit(ret);
. @SGaist is suggesting you try replacing it withreturn ret;
(assuming what you showed is in yourmain()
) in case that makes any difference. Have you tried that?You might put some
qDebug()
or whatever is appropriate immediately above that just to make sure whether your app really is exiting theexec()
loop. -
@SMF-Qt
But your code shows you usingexit(ret);
. @SGaist is suggesting you try replacing it withreturn ret;
(assuming what you showed is in yourmain()
) in case that makes any difference. Have you tried that?You might put some
qDebug()
or whatever is appropriate immediately above that just to make sure whether your app really is exiting theexec()
loop. -
As I wrote before, just returning to the shell does not mean your application is closed.
You have to explicitly close it. -
As I wrote before, just returning to the shell does not mean your application is closed.
You have to explicitly close it. -
AFAIR, if you swipe from the bottom up, it should show you all the applications that are running and you can there stop them.
-
AFAIR, if you swipe from the bottom up, it should show you all the applications that are running and you can there stop them.
-
Depending on what you have in mind, a QTimer calling the application quit slot might do what you want.
-
Depending on what you have in mind, a QTimer calling the application quit slot might do what you want.
Thanks but I have a quit button on my app which calls QWidget::close on the top level widget which shuts down my application apart from the database which is handled by main.
I have set app->setQuitOnLastWindowClosed(true); and app->exec() is returning 0 so everything is shutdown. once app->exec() returns the database is closed and the app destructors are run via the delete app at the very end of main. I am confident having debugged the emulated version of my app that my code is shutting everything down and exiting with a return value of 0. -
Thanks but I have a quit button on my app which calls QWidget::close on the top level widget which shuts down my application apart from the database which is handled by main.
I have set app->setQuitOnLastWindowClosed(true); and app->exec() is returning 0 so everything is shutdown. once app->exec() returns the database is closed and the app destructors are run via the delete app at the very end of main. I am confident having debugged the emulated version of my app that my code is shutting everything down and exiting with a return value of 0.@SMF-Qt
I have noticed that after I click the Quit button and my application has exited main I sometimes get the following abort message from the QtCreator debugger:W/qtMainLoopThrea: type=1400 audit(0.0:64483): avc: denied { read } for name="/" dev="tmpfs" ino=1 scontext=u:r:untrusted_app:s0:c209,c256,c512,c768 tcontext=u:object_r:device:s0 tclass=dir permissive=0 app=com.home.QtTest4
W/qtMainLoopThrea: type=1400 audit(0.0:64484): avc: denied { read } for name="devices" dev="sysfs" ino=4521 scontext=u:r:untrusted_app:s0:c209,c256,c512,c768 tcontext=u:object_r:sysfs:s0 tclass=dir permissive=0 app=com.home.QtTest4
D/EGL_emulation: app_time_stats: avg=171.19ms min=6.22ms max=947.76ms count=6
I/ImeTracker: com.home.QtTest4:89e0e728: onRequestHide at ORIGIN_CLIENT reason HIDE_SOFT_INPUT fromUser false
I/ImeTracker: com.home.QtTest4:c4e121a7: onRequestHide at ORIGIN_CLIENT reason HIDE_SOFT_INPUT fromUser false
D/EGL_emulation: app_time_stats: avg=2462.04ms min=33.03ms max=10232.86ms count=5
I/default : main() returned 0
D/VRI[QtActivity]: visibilityChanged oldVisibility=true newVisibility=false
W/default : java.lang.NullPointerException: Attempt to invoke virtual method 'void android.content.Context.unregisterReceiver(android.content.BroadcastReceiver)' on a null object reference
W/default : at org.qtproject.qt.android.network.QtNetwork.unregisterReceiver(QtNetwork.java:49)
W/default : at org.qtproject.qt.android.QtNative.startQtApplication(Native Method)
W/default : at org.qtproject.qt.android.QtNative$$ExternalSyntheticLambda4.run(D8$$SyntheticClass:0)
W/default : at org.qtproject.qt.android.QtThread$1.run(QtThread.java:25)
W/default : at java.lang.Thread.run(Thread.java:1012)
W/default :
F/libc : FORTIFY: pthread_mutex_lock called on a destroyed mutex (0x749993a02ab8)
F/libc : FORTIFY: pthread_mutex_lock called on a destroyed mutex (0x749993a02ab8)
F/libc : Fatal signal 6 (SIGABRT), code -1 (SI_QUEUE) in tid 20289 (hwuiTask0), pid 20225 (.home.QtTest4)
09:24:14: Android target "com.home.QtTest4" died. -
S SMF-Qt referenced this topic