From bdad4dce4264e181c2b09195637d655f2164ccf4 Mon Sep 17 00:00:00 2001
From: Přemysl Janouch
Date: Sun, 3 May 2015 19:18:13 +0200
Subject: config: fix config_item_set_from()
---
common.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/common.c b/common.c
index 1ec8cee..936b840 100644
--- a/common.c
+++ b/common.c
@@ -705,9 +705,9 @@ config_item_set_from (struct config_item_ *self, struct config_item_ *source,
return false;
// Make sure the string subtype fits the schema
- if (config_item_type_is_string (self->type)
- && config_item_type_is_string (source->type))
- source->type = self->type;
+ if (config_item_type_is_string (source->type)
+ && config_item_type_is_string (schema->type))
+ source->type = schema->type;
config_item_move (self, source);
--
cgit v1.2.3-70-g09d2