diff --git a/sflphone-client-gnome/src/config/accountconfigdialog.c b/sflphone-client-gnome/src/config/accountconfigdialog.c index 0b0d23e9e91ddb42b057148824f85ccde385ab77..fa8606818e3e4ec91ed0568cf27c7528900cb52f 100644 --- a/sflphone-client-gnome/src/config/accountconfigdialog.c +++ b/sflphone-client-gnome/src/config/accountconfigdialog.c @@ -1070,14 +1070,26 @@ show_account_window (account_t * a) g_hash_table_replace(currentAccount->properties, g_strdup(LOCAL_ADDRESS), g_strdup((gchar *)gtk_combo_box_get_active_text(GTK_COMBO_BOX(localAddressCombo)))); + if(!gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(sameAsLocalRadioButton))) + { + g_hash_table_replace(currentAccount->properties, + g_strdup(PUBLISHED_PORT), + g_strdup((gchar *)gtk_entry_get_text(GTK_ENTRY(publishedPortSpinBox)))); + + g_hash_table_replace(currentAccount->properties, + g_strdup(PUBLISHED_ADDRESS), + g_strdup((gchar *)gtk_entry_get_text(GTK_ENTRY(publishedAddressEntry)))); + } + else { - g_hash_table_replace(currentAccount->properties, - g_strdup(PUBLISHED_PORT), - g_strdup((gchar *)gtk_entry_get_text(GTK_ENTRY(publishedPortSpinBox)))); + g_hash_table_replace(currentAccount->properties, + g_strdup(PUBLISHED_PORT), + g_strdup((gchar *)gtk_entry_get_text(GTK_ENTRY(localPortSpinBox)))); - g_hash_table_replace(currentAccount->properties, - g_strdup(PUBLISHED_ADDRESS), - g_strdup((gchar *)gtk_entry_get_text(GTK_ENTRY(publishedAddressEntry)))); + g_hash_table_replace(currentAccount->properties, + g_strdup(PUBLISHED_ADDRESS), + g_strdup((gchar *)gtk_combo_box_get_active_text(GTK_COMBO_BOX(localAddressCombo)))); + } /* DEBUG("-------- Basic parameters to ne written in config"); DEBUG("curAccountID %s, curAccountType %s, curAlias %s, curHostname %s, curPassword %s, curUsername %s, curMailbox %s\n",