gnokii-users
[Top][All Lists]
Advanced

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

Re: stupid bug in xgnokii phonebook editor


From: Pawel Kot
Subject: Re: stupid bug in xgnokii phonebook editor
Date: Wed, 29 Feb 2012 18:21:48 +0100

Hi,

On Wed, Feb 29, 2012 at 17:30, Christoph Rudorff <address@hidden> wrote:
> On 29.02.2012 10:23, Pawel Kot wrote:
>>>> I think it is some old code that was introduced in order to support
>>>> correctly EXTPBK when one number was stored only. At least some models
>>>> required to replicate the main number as the subentry. I do not think
>>>> we have cared about multiple subentries at that time.
>>>
>>> LoL. That said, it just works by accident?
>>
>> Sorry, do not get your point. What does work by accident?
>>
>>>>
>>>>> xgnokii/xgnokii_contacts.c line 395 in EditPhonebookEntry()
>>>>>
>>>>> if (phoneMonitor.supported & PM_EXTPBK) {
>>> ...
>>>>> current_entry->entry.subentries[0].number_type = ...
>>>>> current_entry->entry.subentries_count = 1;
>>> ...
>>>>
>>>> That's plain simple. We're creating a subentry which is equal to the
>>>> main number.
>
> That is already done! (see OkEditNumbersDialog). The 1st subentry is
> already set as main number.

You mean this? It does the opposite.
if (g_strncasecmp(row_data, "*", 1) == 0) {
         found = gtk_clist_get_text(GTK_CLIST(editNumbersData.clist),
i, 1, &row_data);
         memcpy(editEntryData->pbEntry->entry.number, row_data,
strlen(row_data) + 1);
} else {

> Well, the code looks like it knows how to handle subentries.

As far as I can see it wouldn't work in case when there are no subentries.

> It just looked stupid to me, that here the subentries_count is set to 1
> and therefore ignoring the other entries and so they get lost.

The code is OK, but the condition seems wrong.

>>> Well, after some playing with the subentry types I noticed xgnoki doesn't
>>> report about transfer errors except on stderr: e.g. A note may contain
>>> chars and numbers not. But that's it ...
>>
>> You mean debug log or additional error information without debug log?
>
> No, I mean if you fix the subentry issue, this leads then to another bug:
> Transfer errors are silently ignored by the GUI. As a user, you just
> wonder why some phone entries are missing on the real phone.
>
> Create a phone book entry like this:
[...]
> So there it needs an error handling. Idea: mark the entry red in the gui?!

Probably you should be able to show the error message somehow. Anyway
patches are welcome.

take care,
-- 
Pawel Kot



reply via email to

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