mirror of
git://xwords.git.sourceforge.net/gitroot/xwords/xwords
synced 2025-02-15 20:48:00 +01:00
more ANR/crash logging
This commit is contained in:
parent
f4c080cdf7
commit
e4f10d4850
2 changed files with 15 additions and 3 deletions
|
@ -176,10 +176,12 @@ abstract class XWFragment: Fragment(), Delegator {
|
||||||
|
|
||||||
override fun onDestroy()
|
override fun onDestroy()
|
||||||
{
|
{
|
||||||
Log.d( TAG, "%H/%s.onDestroy() called", this, this::class.java.getSimpleName() )
|
val simpleName = this::class.java.getSimpleName()
|
||||||
|
Log.d( TAG, "%H/%s.onDestroy() called", this, simpleName )
|
||||||
mDlgt?.onDestroy()
|
mDlgt?.onDestroy()
|
||||||
sActiveFrags.remove( this )
|
sActiveFrags.remove( this )
|
||||||
super.onDestroy()
|
super.onDestroy()
|
||||||
|
Log.d( TAG, "%H/%s.onDestroy() finished", this, simpleName )
|
||||||
}
|
}
|
||||||
|
|
||||||
@Deprecated("Deprecated in Java")
|
@Deprecated("Deprecated in Java")
|
||||||
|
|
|
@ -32,7 +32,12 @@
|
||||||
|
|
||||||
#ifdef DEBUG
|
#ifdef DEBUG
|
||||||
# define MAGIC_INITED 0x8283413F
|
# define MAGIC_INITED 0x8283413F
|
||||||
# define ASSERT_MAGIC() XP_ASSERT(dutil->magic == MAGIC_INITED)
|
# define ASSERT_MAGIC() { \
|
||||||
|
if ( dutil->magic != MAGIC_INITED ) { \
|
||||||
|
XP_LOGFF( "bad magic %X", dutil->magic ); \
|
||||||
|
XP_ASSERT(0); \
|
||||||
|
} \
|
||||||
|
}
|
||||||
#else
|
#else
|
||||||
# define ASSERT_MAGIC()
|
# define ASSERT_MAGIC()
|
||||||
#endif
|
#endif
|
||||||
|
@ -324,7 +329,7 @@ dvc_getMQTTSubTopics( XW_DUtilCtxt* dutil, XWEnv xwe,
|
||||||
|
|
||||||
*qos = dvc_getQOS( dutil, xwe );
|
*qos = dvc_getQOS( dutil, xwe );
|
||||||
|
|
||||||
logPtrs( __func__, *nTopics, topics );
|
// logPtrs( __func__, *nTopics, topics );
|
||||||
}
|
}
|
||||||
|
|
||||||
typedef enum { CMD_INVITE, CMD_MSG, CMD_DEVGONE, } MQTTCmd;
|
typedef enum { CMD_INVITE, CMD_MSG, CMD_DEVGONE, } MQTTCmd;
|
||||||
|
@ -654,6 +659,8 @@ dvc_parseMQTTPacket( XW_DUtilCtxt* dutil, XWEnv xwe, const XP_UCHAR* topic,
|
||||||
MQTTDevID myID;
|
MQTTDevID myID;
|
||||||
dvc_getMQTTDevID( dutil, xwe, &myID );
|
dvc_getMQTTDevID( dutil, xwe, &myID );
|
||||||
|
|
||||||
|
XP_LOGFF( "got myID" );
|
||||||
|
|
||||||
XP_U32 gameID = 0;
|
XP_U32 gameID = 0;
|
||||||
if ( isDevMsg( &myID, topic, &gameID ) ) {
|
if ( isDevMsg( &myID, topic, &gameID ) ) {
|
||||||
XP_LOGFF( "is msg; gameID: %X", gameID );
|
XP_LOGFF( "is msg; gameID: %X", gameID );
|
||||||
|
@ -715,7 +722,10 @@ dvc_parseMQTTPacket( XW_DUtilCtxt* dutil, XWEnv xwe, const XP_UCHAR* topic,
|
||||||
}
|
}
|
||||||
stream_destroy( stream );
|
stream_destroy( stream );
|
||||||
} else if ( isCtrlMsg( &myID, topic ) ) {
|
} else if ( isCtrlMsg( &myID, topic ) ) {
|
||||||
|
XP_LOGFF( "is ctrl msg" );
|
||||||
dutil_onCtrlReceived( dutil, xwe, buf, len );
|
dutil_onCtrlReceived( dutil, xwe, buf, len );
|
||||||
|
} else {
|
||||||
|
XP_LOGFF( "OTHER" );
|
||||||
}
|
}
|
||||||
LOG_RETURN_VOID();
|
LOG_RETURN_VOID();
|
||||||
} /* dvc_parseMQTTPacket */
|
} /* dvc_parseMQTTPacket */
|
||||||
|
|
Loading…
Add table
Reference in a new issue