profile_name_is_valid() returns a malloced string [-Wcast-qual]
Change-Id: I584cdbf6a09e818e0d14c951defdde2fc96787f3 Reviewed-on: https://code.wireshark.org/review/13440 Reviewed-by: João Valverde <j@v6e.pt>
This commit is contained in:
parent
4dd3f668dc
commit
faedd049af
|
@ -726,7 +726,7 @@ profile_name_edit_ok(GtkWidget *w _U_, gpointer parent_w)
|
|||
if (strlen(new_name) == 0) {
|
||||
return;
|
||||
}
|
||||
valid_name = (char*)profile_name_is_valid(new_name);
|
||||
valid_name = profile_name_is_valid(new_name);
|
||||
if (valid_name != NULL) {
|
||||
g_free(valid_name);
|
||||
return;
|
||||
|
|
|
@ -348,7 +348,7 @@ init_profile_list(void)
|
|||
copy_profile_list ();
|
||||
}
|
||||
|
||||
const gchar *
|
||||
gchar *
|
||||
profile_name_is_valid(const gchar *name)
|
||||
{
|
||||
gchar *reason = NULL;
|
||||
|
|
|
@ -115,7 +115,7 @@ const gchar *get_profile_parent (const gchar *profilename);
|
|||
* @param name Profile name
|
||||
* @return NULL if the name is valid or an error message otherwise.
|
||||
*/
|
||||
const gchar *profile_name_is_valid(const gchar *name);
|
||||
gchar *profile_name_is_valid(const gchar *name);
|
||||
|
||||
/** Remove the current profile.
|
||||
*
|
||||
|
|
Loading…
Reference in New Issue