Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
jami-daemon
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
savoirfairelinux
jami-daemon
Commits
a060b849
Commit
a060b849
authored
14 years ago
by
Alexandre Savard
Browse files
Options
Downloads
Patches
Plain Diff
[#3902] Relax async calls on gdk_main_loop in multithreads
parent
3f5a3720
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
sflphone-client-gnome/src/callable_obj.c
+2
-1
2 additions, 1 deletion
sflphone-client-gnome/src/callable_obj.c
sflphone-client-gnome/src/mainwindow.c
+14
-7
14 additions, 7 deletions
sflphone-client-gnome/src/mainwindow.c
with
16 additions
and
8 deletions
sflphone-client-gnome/src/callable_obj.c
+
2
−
1
View file @
a060b849
...
...
@@ -177,10 +177,11 @@ void threaded_clock_incrementer (void *pc)
calltree_update_clock
();
}
// gdk_flush();
gdk_threads_leave
();
usleep
(
10000
);
usleep
(
10000
00
);
}
...
...
This diff is collapsed.
Click to expand it.
sflphone-client-gnome/src/mainwindow.c
+
14
−
7
View file @
a060b849
...
...
@@ -61,7 +61,8 @@ GtkWidget * filterEntry = NULL;
PidginScrollBook
*
embedded_error_notebook
;
gchar
*
status_current_message
=
NULL
;
pthread_mutex_t
statusbar_message_mutex
;
// pthread_mutex_t statusbar_message_mutex;
GMutex
*
gmutex
;
/**
* Handle main window resizing
...
...
@@ -96,7 +97,8 @@ on_delete (GtkWidget * widget UNUSED, gpointer data UNUSED)
sflphone_quit
();
}
pthread_mutex_destroy
(
&
statusbar_message_mutex
);
// pthread_mutex_destroy (&statusbar_message_mutex);
g_mutex_free
(
gmutex
);
return
TRUE
;
}
...
...
@@ -294,7 +296,8 @@ create_main_window ()
/* don't show waiting layer */
gtk_widget_hide
(
waitingLayer
);
pthread_mutex_init
(
&
statusbar_message_mutex
,
NULL
);
// pthread_mutex_init (&statusbar_message_mutex, NULL);
gmutex
=
g_mutex_new
();
// Configuration wizard
if
(
account_list_get_size
()
==
1
)
{
...
...
@@ -407,7 +410,8 @@ statusbar_push_message (const gchar *left_hand_message, const gchar *right_hand_
// The actual message to be push in the statusbar
gchar
*
message_to_display
;
pthread_mutex_lock
(
&
statusbar_message_mutex
);
g_mutex_lock
(
gmutex
);
// pthread_mutex_lock (&statusbar_message_mutex);
g_free
(
status_current_message
);
// store the left hand message so that it can be reused in case of clock update
...
...
@@ -425,7 +429,8 @@ statusbar_push_message (const gchar *left_hand_message, const gchar *right_hand_
g_free
(
message_to_display
);
pthread_mutex_unlock
(
&
statusbar_message_mutex
);
// pthread_mutex_unlock (&statusbar_message_mutex);
g_mutex_unlock
(
gmutex
);
}
void
...
...
@@ -445,9 +450,11 @@ statusbar_update_clock (gchar *msg)
}
pthread_mutex_lock
(
&
statusbar_message_mutex
);
// pthread_mutex_lock (&statusbar_message_mutex);
g_mutex_lock
(
gmutex
);
message
=
g_strdup
(
status_current_message
);
pthread_mutex_unlock
(
&
statusbar_message_mutex
);
// pthread_mutex_unlock (&statusbar_message_mutex);
g_mutex_unlock
(
gmutex
);
if
(
message
)
{
statusbar_pop_message
(
__MSG_ACCOUNT_DEFAULT
);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment