gnokii-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: gnokii + kaddressbook + encoding


From: Pawel Kot
Subject: Re: gnokii + kaddressbook + encoding
Date: Mon, 31 May 2004 23:20:19 +0200 (CEST)

On Mon, 31 May 2004, Pawel Kot wrote:

> On Mon, 31 May 2004, Helge Deller wrote:
>
> > "Jürgen Ölm" instead of "Jürgen Öhme"
>
> Could you also tell me what is the strlen() of these 2 strings. With my
> tests it looks correct, but it may be the reason...

OK. Assuming that you use nk6510.c driver, please try the below patch. Id
this is the other driver patch the WritePhonebook() function in the
similiar manner. Hope it will work.

--- common/phones/nk6510.c~     2004-05-31 23:08:02.000000000 +0200
+++ common/phones/nk6510.c      2004-05-31 23:14:31.000000000 +0200
@@ -1750,11 +1750,9 @@
        block = 1;
        if (!entry->empty) {
                /* Name */
-               j = strlen(entry->name);
-               char_unicode_encode((string + 1), entry->name, j);
-               /* Length ot the string + length field + terminating 0 */
-               string[0] = j * 2;
-               count += PackBlock(0x07, j * 2 + 1, block++, string, req + 
count, GN_PHONEBOOK_ENTRY_MAX_LENGTH - count);
+               j = char_unicode_encode((string + 1), entry->name, 
strlen(entry->name));
+               string[0] = j;
+               count += PackBlock(0x07, j + 1, block++, string, req + count, 
GN_PHONEBOOK_ENTRY_MAX_LENGTH - count);

                /* Group */
                string[0] = entry->caller_group + 1;

take care,
pkot
-- 
p k o t a t b e z s e n s u d o t p l
http://www.gnokii.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]