use different uuid for dbg variant so it's not cross-sending BT

messages with other variants, causing among other problems spurious
"deleted on other device" warnings.
This commit is contained in:
Eric House 2015-07-29 19:48:56 -07:00
parent 3732321825
commit 65606607ab
4 changed files with 11 additions and 2 deletions

View file

@ -42,6 +42,7 @@ LOCAL_DEFINES += \
-DNATIVE_NLI \
-DCOMMS_VERSION=1 \
-DINITIAL_CLIENT_VERS=${INITIAL_CLIENT_VERS} \
-DVARIANT=\"${VARIANT}\" \
-DRELAY_ROOM_DEFAULT=\"\" \
-D__LITTLE_ENDIAN \

View file

@ -565,8 +565,14 @@ Java_org_eehouse_android_xw4_jni_XwJNI_comms_1getUUID
{
jstring jstr = NULL;
#ifdef XWFEATURE_BLUETOOTH
const char* uuid = XW_BT_UUID;
XP_LOGF( "uuid: %s", uuid );
const char* uuid;
if ( 0 == XP_STRCMP( VARIANT, "xw4" ) ) {
uuid = XW_BT_UUID;
} else if ( 0 == XP_STRCMP( VARIANT, "xw4dbg" ) ) {
uuid = XW_BT_UUID_DBG;
} else {
XP_ASSERT(0);
}
jstr = (*env)->NewStringUTF( env, uuid );
#endif
return jstr;

View file

@ -35,6 +35,7 @@
<arg value="INITIAL_CLIENT_VERS=${INITIAL_CLIENT_VERS}" />
<arg value="CHAT_ENABLED=${CHAT_ENABLED}" />
<arg value="THUMBNAIL_ENABLED=${THUMBNAIL_ENABLED}" />
<arg value="VARIANT=${VARIANT_NAME}" />
</exec>
<exec dir="." executable="../scripts/mkimages.sh"

View file

@ -59,6 +59,7 @@ typedef enum {
#ifdef XWFEATURE_BLUETOOTH
# define XW_BT_UUID "7be0d084-ff89-4d6d-9c78-594773a6f963"
# define XW_BT_UUID_DBG "b079b640-35fe-11e5-a432-0002a5d5c51b"
# define XW_BT_NAME "Crosswords"
#endif