again a bitwise or is required
authorAndreas Steffen <andreas.steffen@strongswan.org>
Thu, 30 Jun 2011 20:26:36 +0000 (22:26 +0200)
committerAndreas Steffen <andreas.steffen@strongswan.org>
Thu, 30 Jun 2011 20:26:36 +0000 (22:26 +0200)
src/libimcv/imc/imc_agent.c
src/libimcv/imv/imv_agent.c

index 94f1c1b..82778a5 100644 (file)
@@ -373,7 +373,7 @@ imc_agent_t *imc_agent_create(const char *name,
                        .destroy = _destroy,
                },
                .name = name,
-               .type = (vendor_id << 8) | (subtype && 0xff),
+               .type = (vendor_id << 8) | (subtype & 0xff),
                .id = id,
                .connections = linked_list_create(),
                .connection_lock = rwlock_create(RWLOCK_TYPE_DEFAULT),
index bf99568..290bb11 100644 (file)
@@ -513,7 +513,7 @@ imv_agent_t *imv_agent_create(const char *name,
                        .destroy = _destroy,
                },
                .name = name,
-               .type = (vendor_id << 8) | (subtype && 0xff),
+               .type = (vendor_id << 8) | (subtype & 0xff),
                .id = id,
                .connections = linked_list_create(),
                .connection_lock = rwlock_create(RWLOCK_TYPE_DEFAULT),