fix android crash due to bad build.gradle merge

and add pid to curses app display
This commit is contained in:
Eric House 2020-01-30 21:21:45 -08:00
parent 845dea6eec
commit e9882b45da
2 changed files with 10 additions and 1 deletions

View file

@ -15,6 +15,11 @@ def BT_UUIDS = [
'xw4NoSMSRelease' : XW_UUID, 'xw4NoSMSRelease' : XW_UUID,
'xw4SMSDebug' : XW_UUID, 'xw4SMSDebug' : XW_UUID,
'xw4SMSRelease' : XW_UUID, 'xw4SMSRelease' : XW_UUID,
'xw4dRelease' : XWD_UUID,
'xw4dDebug' : XWD_UUID,
'xw4dNoSMSRelease' : XWD_UUID,
'xw4dNoSMSDebug' : XWD_UUID,
] ]
// AID must start with F (first 4 bits) and be from 5 to 16 bytes long // AID must start with F (first 4 bits) and be from 5 to 16 bytes long

View file

@ -19,6 +19,8 @@
#include <ncurses.h> #include <ncurses.h>
#include <glib.h> #include <glib.h>
#include <sys/types.h>
#include <unistd.h>
#include "curgamlistwin.h" #include "curgamlistwin.h"
@ -29,6 +31,7 @@ struct CursGameList {
int yOffset; int yOffset;
GSList* games; GSList* games;
sqlite3* pDb; sqlite3* pDb;
int pid;
}; };
static void adjustCurSel( CursGameList* cgl ); static void adjustCurSel( CursGameList* cgl );
@ -42,6 +45,7 @@ cgl_init( sqlite3* pDb, int width, int height )
XP_LOGF( "%s(): made window with height=%d, width=%d", __func__, height, width ); XP_LOGF( "%s(): made window with height=%d, width=%d", __func__, height, width );
cgl->width = width; cgl->width = width;
cgl->height = height; cgl->height = height;
cgl->pid = getpid();
return cgl; return cgl;
} }
@ -277,7 +281,7 @@ cgl_draw( CursGameList* cgl )
} }
char buf[cgl->width + 1]; char buf[cgl->width + 1];
snprintf( buf, VSIZE(buf), "%d games total", nGames ); snprintf( buf, VSIZE(buf), "pid: %d; nGames: %d", cgl->pid, nGames );
mvwaddstr( win, 0, 0, buf ); mvwaddstr( win, 0, 0, buf );
wrefresh( win ); wrefresh( win );