[dia] [warningectomy] Assignment within conditional expression
- From: Hans Breuer <hans src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [dia] [warningectomy] Assignment within conditional expression
- Date: Sun, 13 Dec 2009 19:12:02 +0000 (UTC)
commit 72307ed7f7b5ec792965cbc92f4448be5f63f4cd
Author: Hans Breuer <hans breuer org>
Date: Sun Dec 13 13:34:44 2009 +0100
[warningectomy] Assignment within conditional expression
diagramdata.c:378: warning: suggest parentheses around assignment
used as truth value
lib/diagramdata.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/lib/diagramdata.c b/lib/diagramdata.c
index 062bc70..f4c3b32 100644
--- a/lib/diagramdata.c
+++ b/lib/diagramdata.c
@@ -375,7 +375,7 @@ data_object_get_highlight(DiagramData *data, DiaObject *obj)
{
ObjectHighlight *oh;
DiaHighlightType type = DIA_HIGHLIGHT_NONE;
- if (oh = find_object_highlight (data->highlighted, obj)) {
+ if ((oh = find_object_highlight (data->highlighted, obj)) != NULL) {
type = oh->type;
}
return type;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]