From 0f7d924a8eb1f661c4a64d9881c8b394ebdafa09 Mon Sep 17 00:00:00 2001 From: Eric House Date: Mon, 28 Sep 2020 16:12:24 -0700 Subject: [PATCH] accept dicts with full paths (linux) --- xwords4/linux/linuxdict.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/xwords4/linux/linuxdict.c b/xwords4/linux/linuxdict.c index fcf477140..e5c4d6c6e 100644 --- a/xwords4/linux/linuxdict.c +++ b/xwords4/linux/linuxdict.c @@ -158,7 +158,9 @@ initFromDictFile( LinuxDictionaryCtxt* dctx, const LaunchParams* params, XP_U32 topOffset; char path[256]; - if ( !getDictPath( params, fileName, path, VSIZE(path) ) ) { + if ( file_exists( fileName ) ) { + snprintf( path, VSIZE(path), "%s", fileName ); + } else if ( !getDictPath( params, fileName, path, VSIZE(path) ) ) { XP_LOGF( "%s: path=%s", __func__, path ); goto closeAndExit; }