Qt World Summit: Register Today!

Switching from Qt 5.1 to Qt 5.2 is causing app to crash

  • I recently downloaded Qt 5.2 and I loaded my working app from Qt 5.1 into it and it keeps crashing because it says that it is calling "startRecording()" on an uninitiated AudioRecord. Here is the error when the initialization fails
    @E/AudioRecord(14313): AudioFlinger could not create record track, status: -1
    E/AudioRecord-JNI(14313): Error creating AudioRecord instance: initialization check failed.
    E/AudioRecord-Java(14313): [ android.media.AudioRecord ] Error code -20 when initializing native AudioRecord object.@
    Here is the error where an exception is thrown causing the program to crash
    @E/AndroidRuntime(14313): FATAL EXCEPTION: Thread-855
    E/AndroidRuntime(14313): java.lang.IllegalStateException: startRecording() called on an uninitialized AudioRecord.
    E/AndroidRuntime(14313): at android.media.AudioRecord.startRecording(AudioRecord.java:515)
    E/AndroidRuntime(14313): at dalvik.system.NativeStart.run(Native Method)@
    Has anybody else had troubles with getting their code to run on Qt 5.2?
    Also, I don't this it is a permissions error.

  • Watch out for garbage collection on C++ objects created from qml. The new javascript engine seems to be a more aggressive collector and things you might have just about got away with before might go wrong and require a setObjectOwnership call.

Log in to reply