X-Git-Url: https://git.dogcows.com/gitweb?p=chaz%2Fhomebank;a=blobdiff_plain;f=src%2Fhb-import-ofx.c;fp=src%2Fhb-import-ofx.c;h=701d7326aa0d4bbdc4dbcff0c8d32ff6844eda2a;hp=c5dd6058ab2c76208d50fc9ce33a4d0f74e74214;hb=d11c8dd3275ed2a4a35598e69c0804dcf9435766;hpb=2ef3e601408ebaeeaf5f40d6967664b012a49979 diff --git a/src/hb-import-ofx.c b/src/hb-import-ofx.c index c5dd605..701d732 100644 --- a/src/hb-import-ofx.c +++ b/src/hb-import-ofx.c @@ -1,5 +1,5 @@ /* HomeBank -- Free, easy, personal accounting for everyone. - * Copyright (C) 1995-2017 Maxime DOYEN + * Copyright (C) 1995-2018 Maxime DOYEN * * This file is part of HomeBank. * @@ -263,7 +263,7 @@ Transaction *newope; { case 1: //to memo DB( g_print(" -> name to memo: '%s'\n", data.name) ); - newope->wording = g_strdup(data.name); + newope->memo = g_strdup(data.name); //test //strip_extra_spaces(newope->wording); @@ -281,7 +281,13 @@ Transaction *newope; g_strstrip(name); //test //strip_extra_spaces(name); - + + #ifndef G_OS_UNIX + DB( g_print(" ensure UTF-8\n") ); + + name = homebank_utf8_ensure(name); + #endif + DB( g_print(" -> name to payee: '%s'\n", name) ); payitem = da_pay_get_by_name(name); @@ -330,12 +336,12 @@ Transaction *newope; break; case 2: //add to description - old = newope->wording; + old = newope->memo; if(old == NULL) - newope->wording = g_strdup(data.memo); + newope->memo = g_strdup(data.memo); else { - newope->wording = g_strjoin(" ", old, data.memo, NULL); + newope->memo = g_strjoin(" ", old, data.memo, NULL); g_free(old); }