[gnome-builder] file-settings: be defensive about assignment
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-builder] file-settings: be defensive about assignment
- Date: Wed, 19 Jul 2017 11:13:20 +0000 (UTC)
commit 03f743a533f6a37e428c2215174ba18b8dc98c59
Author: Christian Hergert <chergert redhat com>
Date: Fri Jul 7 19:20:32 2017 -0700
file-settings: be defensive about assignment
This just ensures that the previous statement had a proper
end semicolon. Otherwise we could do a = b = priv->foo_set on
accident.
libide/files/ide-file-settings.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/libide/files/ide-file-settings.c b/libide/files/ide-file-settings.c
index 2dd8329..3c6cf42 100644
--- a/libide/files/ide-file-settings.c
+++ b/libide/files/ide-file-settings.c
@@ -108,7 +108,7 @@ void ide_file_settings_set_##name (IdeFileSettings *self, \
{ \
IdeFileSettingsPrivate *priv = ide_file_settings_get_instance_private (self); \
g_return_if_fail (IDE_IS_FILE_SETTINGS (self)); \
- assign_stmt \
+ G_STMT_START { assign_stmt } G_STMT_END; \
priv->name##_set = TRUE; \
g_object_notify_by_pspec (G_OBJECT (self), properties [PROP_##NAME]); \
g_object_notify_by_pspec (G_OBJECT (self), properties [PROP_##NAME##_SET]); \
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]