[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Segfault in xgnokii
From: |
Ulrich Hopp |
Subject: |
Segfault in xgnokii |
Date: |
Wed, 4 Dec 2002 23:17:36 +0100 |
User-agent: |
KMail/1.4.3 |
Hi,
gnokii : latest version from CVS 0.5.0pre (04.12.2002)
Phone : Nokia 6310 V 4.10 04-01-02 NPE-4
Cabel : DLR3-3P
System SuSE 8.1 ( ftp update )
While trying to change a phone number in xgnokii I got a segfault.
Trying to debug this I found that the last lines executed before segfaulting
are these
xgnokii_contacts.c line 427 :
**************************
if (phoneMonitor.supported & PM_EXTPBK) {
number = g_malloc(sizeof(char) *
max_phonebook_number_length);
gtk_label_get(GTK_LABEL(((EditEntryData *)
data)->number), number);
**************************
after this line the segfault happens :
**************************
snprintf(entry->entry.Number,
max_phonebook_number_length, "%s",
number[0]);
snprintf(entry->entry.SubEntries[0].data.Number,
max_phonebook_number_length, "%s", number[0]);
entry->entry.SubEntries[0].EntryType =
GSM_Number;
entry->entry.SubEntries[0].NumberType =
GSM_General;
entry->entry.SubEntriesCount = 1;
g_free(number);
**************************
It seems that structure entry is not initialized here ( debugger says entry =
0x0 )
After changing entry->..... to ((EditEntry_Data *) Data ) pbEntry->..... the
segfault disappeared but I don't know if I'm right.
Or should entry be initialized here ?
regards
Uli
- Segfault in xgnokii,
Ulrich Hopp <=