After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 787146 - GMainLoop: match of parameter pair of LOCK_CONTEXT/UNLOCK_CONTEXT
GMainLoop: match of parameter pair of LOCK_CONTEXT/UNLOCK_CONTEXT
Status: RESOLVED FIXED
Product: glib
Classification: Platform
Component: mainloop
unspecified
Other All
: Normal enhancement
: ---
Assigned To: gtkdev
gtkdev
Depends on:
Blocks:
 
 
Reported: 2017-09-01 17:33 UTC by insun.pyo
Modified: 2017-09-08 14:58 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
patch (820 bytes, patch)
2017-09-01 17:33 UTC, insun.pyo
committed Details | Review

Description insun.pyo 2017-09-01 17:33:16 UTC
Created attachment 358955 [details] [review]
patch

The parameter mismatch between LOCK_CONTEXT and UNLOCK_CONTEXT in g_source_set_priority.

To avoid confusion, change to the parameter used in LOCK_CONTEXT.


///////////////////////////////////////////////////////////////////////////////
void g_source_set_priority (GSource  *source, gint      priority)
{
  context = source->context;

  if (context)
    LOCK_CONTEXT (context);

  g_source_set_priority_unlocked (source, context, priority);

  if (context)
    UNLOCK_CONTEXT (source->context);
}
//////////////////////////////////////////////////////////////////////////////
Comment 1 Colin Walters 2017-09-01 19:38:58 UTC
Review of attachment 358955 [details] [review]:

LGTM.