diff --git a/include/maestro/core.h b/include/maestro/core.h index 33f7eb3ee00749c70b0dd5e36806c81a618374cd..38b7bf4e02dc72910e61b23f3b03a32227aa8f96 100644 --- a/include/maestro/core.h +++ b/include/maestro/core.h @@ -44,6 +44,7 @@ extern "C" { #include "maestro/cdo.h" #include "maestro/pool.h" #include "maestro/pool_manager.h" + #include "maestro/attributes.h" #include <stdint.h> /**@defgroup MSTRO_Core Maestro Core API diff --git a/tests/check_transport_mio.c b/tests/check_transport_mio.c index 9c22d388e39e340be9b57a023d5d115d6955769e..1cf0f20f7033fdeb69dad6bd4287ff4d8ba67a62 100644 --- a/tests/check_transport_mio.c +++ b/tests/check_transport_mio.c @@ -87,20 +87,19 @@ CHEAT_DECLARE ( cheat_assert(MSTRO_OK == mstro_cdo_attribute_set(cdo_src, MSTRO_ATTR_CORE_CDO_SCOPE_LOCAL_SIZE, &bytes)); - enum mstro_cdo_attr_value_types ttype; - const void* tval; + const int64_t* tval; cheat_assert(MSTRO_OK == mstro_cdo_attribute_get(cdo_src, MSTRO_ATTR_CORE_CDO_SCOPE_LOCAL_SIZE, - &ttype, - &tval)); + NULL, + (const void**)&tval)); cheat_assert(*(const uint64_t*)tval==bytes); cheat_assert(MSTRO_OK == mstro_cdo_declaration_seal(cdo_src)); cheat_assert(MSTRO_OK == mstro_cdo_attribute_get(cdo_src, MSTRO_ATTR_CORE_CDO_SCOPE_LOCAL_SIZE, - &ttype, - &tval)); - cheat_assert(*(const uint64_t*)tval==bytes); + NULL, + (const void**)&tval)); + cheat_assert(*tval==bytes); cheat_assert(MSTRO_OK == mstro_cdo_declare(name, MSTRO_ATTR_DEFAULT, &cdo_dst)); @@ -131,10 +130,9 @@ CHEAT_DECLARE ( ticket.cdoid = &id; mstro_status status; - enum mstro_cdo_attr_value_types type1; - const void* val1; - cheat_assert(MSTRO_OK == mstro_cdo_attribute_get(cdo_src, "local_size", &type1, &val1)); - ticket.data_size = *(size_t*)val1; + const int64_t* val1; + cheat_assert(MSTRO_OK == mstro_cdo_attribute_get(cdo_src, "scope.local-size", NULL, (const void**)&val1)); + ticket.data_size = *val1; ticket.ticket_case = MSTRO__POOL__TRANSFER_TICKET__TICKET_MIO; Mstro__Pool__TransferTicketMIO mio = MSTRO__POOL__TRANSFER_TICKET_MIO__INIT; @@ -189,7 +187,7 @@ CHEAT_DECLARE ( double* data; size_t len; - enum mstro_cdo_attr_value_types type; + enum mstro_cdo_attr_value_type type; const void* val; cheat_assert(MSTRO_OK == mstro_cdo_access_ptr(cdo_dst, (void**)&data, NULL)); diff --git a/transport/mio.c b/transport/mio.c index 9ce1511b274c89c4f9a80269342e780affc2e8a4..9aaf50bfa650b58b56d64200e6e96b1c58d0a571 100644 --- a/transport/mio.c +++ b/transport/mio.c @@ -3,6 +3,8 @@ #include "transport.h" #include "transport_mio.h" +#include "attributes/maestro-schema.h" + #include <mio.h> /* the MIO one */ #include <limits.h> @@ -546,7 +548,7 @@ mstro_transport_mio_dst_execute(mstro_cdo dst, } if (!(MSTRO_OK == mstro_attribute_dict_set( - dst, MSTRO_ATTR_CORE_CDO_SCOPE_LOCAL_SIZE, MSTRO_CDO_ATTR_VALUE_INVALID, + dst->attributes, MSTRO_ATTR_CORE_CDO_SCOPE_LOCAL_SIZE, MSTRO_CDO_ATTR_VALUE_INVALID, &len, true))) { ERR("Failed to set %s attribute of CDO %s for transport\n", MSTRO_ATTR_CORE_CDO_SCOPE_LOCAL_SIZE, diff --git a/transport/transport.c b/transport/transport.c index bf8cb50576506c07356cd48114abd53e4b3abd02..a03e8c26238bb793725fa8c8e82d70abde27ddf9 100644 --- a/transport/transport.c +++ b/transport/transport.c @@ -149,7 +149,7 @@ mstro_transport_init() MSTRO_ENV_MIO_CONFIG); } else { INFO("Initializing MIO with configuration file %s\n", env_mio_config); - status = mio_init(env_mio_config); + int status = mio_init(env_mio_config); if (status != 0) { ERR("Failed to initialize MIO (errno: %d\n)", status); return MSTRO_FAIL;