Skip to content
Permalink
Browse files

Anjay 1.15.1

Improvements:
- Anjay will never attempt to send Register/Update from anjay_delete
  any more. It used to happen when that message was scheduled to be sent
  at a time that happened to pass between last anjay_sched_run and
  anjay_delete calls.
  • Loading branch information...
dextero committed Feb 19, 2019
1 parent 630ea47 commit b6474835588682d161a207f763dd40a821603133
@@ -15,7 +15,7 @@
cmake_minimum_required(VERSION 2.8.12)

project(anjay C)
set(ANJAY_VERSION "1.15" CACHE STRING "Anjay library version")
set(ANJAY_VERSION "1.15.1" CACHE STRING "Anjay library version")
set(ANJAY_BINARY_VERSION 1.0.0)

set(ANJAY_SOURCE_DIR "${CMAKE_CURRENT_SOURCE_DIR}")
@@ -138,6 +138,12 @@ static void demo_delete(anjay_demo_t *demo) {
}
avs_stream_cleanup(&data);
}

if (demo->schedule_update_on_exit) {
demo_log(INFO, "forced registration update on exit");
anjay_schedule_registration_update(demo->anjay, ANJAY_SSID_ANY);
}

if (demo->anjay) {
anjay_delete(demo->anjay);
}
@@ -53,6 +53,10 @@ struct anjay_demo_struct {
fw_update_logic_t fw_update;

AVS_LIST(anjay_demo_object_t) objects;

// for testing purposes only: causes a Registration Update to be scheduled
// immediately before calling anjay_delete
bool schedule_update_on_exit;
};

const anjay_dm_object_def_t **demo_find_object(anjay_demo_t *demo,
@@ -445,6 +445,12 @@ static void cmd_all_connections_failed(anjay_demo_t *demo,
(int) anjay_all_connections_failed(demo->anjay));
}

static void cmd_schedule_update_on_exit(anjay_demo_t *demo,
const char *unused_args) {
(void) unused_args;
demo->schedule_update_on_exit = true;
}

static void cmd_help(anjay_demo_t *demo, const char *args_string);

struct cmd_handler_def {
@@ -501,6 +507,9 @@ static const struct cmd_handler_def COMMAND_HANDLERS[] = {
"Enables a server with given SSID."),
CMD_HANDLER("get-all-connections-failed", "", cmd_all_connections_failed,
"Returns the result of anjay_all_connections_failed()"),
CMD_HANDLER("schedule-update-on-exit", "", cmd_schedule_update_on_exit,
"Ensure Registration Update is scheduled for immediate "
"execution at the point of calling anjay_delete()"),
CMD_HANDLER("help", "", cmd_help, "Prints this message")
// clang-format on
};
@@ -1,6 +1,13 @@
cmake_minimum_required(VERSION 2.8)
project(attr-storage C)

if(NOT CMAKE_VERSION VERSION_LESS 3.1)
set(CMAKE_C_STANDARD 99)
set(CMAKE_C_EXTENSIONS OFF)
elseif(CMAKE_COMPILER_IS_GNUCC OR CMAKE_C_COMPILER_ID MATCHES "Clang")
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c99")
endif()

find_package(anjay REQUIRED)

set(TUTORIAL_SOURCES
@@ -9,11 +16,4 @@ set(TUTORIAL_SOURCES
include_directories(${ANJAY_INCLUDE_DIRS})

add_executable(${PROJECT_NAME} ${TUTORIAL_SOURCES})
if(NOT CMAKE_VERSION VERSION_LESS 3.1)
set(CMAKE_C_STANDARD 99)
set(CMAKE_C_EXTENSIONS OFF)
elseif(CMAKE_COMPILER_IS_GNUCC OR CMAKE_C_COMPILER_ID MATCHES "Clang")
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c99")
endif()

target_link_libraries(${PROJECT_NAME} ${ANJAY_LIBRARIES_STATIC})
@@ -1,6 +1,13 @@
cmake_minimum_required(VERSION 2.8)
project(persistence C)

if(NOT CMAKE_VERSION VERSION_LESS 3.1)
set(CMAKE_C_STANDARD 99)
set(CMAKE_C_EXTENSIONS OFF)
elseif(CMAKE_COMPILER_IS_GNUCC OR CMAKE_C_COMPILER_ID MATCHES "Clang")
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c99")
endif()

find_package(anjay REQUIRED)

set(TUTORIAL_SOURCES
@@ -9,11 +16,4 @@ set(TUTORIAL_SOURCES
include_directories(${ANJAY_INCLUDE_DIRS})

add_executable(${PROJECT_NAME} ${TUTORIAL_SOURCES})
if(NOT CMAKE_VERSION VERSION_LESS 3.1)
set(CMAKE_C_STANDARD 99)
set(CMAKE_C_EXTENSIONS OFF)
elseif(CMAKE_COMPILER_IS_GNUCC OR CMAKE_C_COMPILER_ID MATCHES "Clang")
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c99")
endif()

target_link_libraries(${PROJECT_NAME} ${ANJAY_LIBRARIES_STATIC})
@@ -1,6 +1,13 @@
cmake_minimum_required(VERSION 2.8)
project(dtls-cert C)

if(NOT CMAKE_VERSION VERSION_LESS 3.1)
set(CMAKE_C_STANDARD 99)
set(CMAKE_C_EXTENSIONS OFF)
elseif(CMAKE_COMPILER_IS_GNUCC OR CMAKE_C_COMPILER_ID MATCHES "Clang")
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c99")
endif()

find_package(anjay REQUIRED)

set(TUTORIAL_SOURCES
@@ -9,11 +16,4 @@ set(TUTORIAL_SOURCES
include_directories(${ANJAY_INCLUDE_DIRS})

add_executable(${PROJECT_NAME} ${TUTORIAL_SOURCES})
if(NOT CMAKE_VERSION VERSION_LESS 3.1)
set(CMAKE_C_STANDARD 99)
set(CMAKE_C_EXTENSIONS OFF)
elseif(CMAKE_COMPILER_IS_GNUCC OR CMAKE_C_COMPILER_ID MATCHES "Clang")
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c99")
endif()

target_link_libraries(${PROJECT_NAME} ${ANJAY_LIBRARIES_STATIC})
@@ -1,6 +1,13 @@
cmake_minimum_required(VERSION 2.8)
project(dtls-psk C)

if(NOT CMAKE_VERSION VERSION_LESS 3.1)
set(CMAKE_C_STANDARD 99)
set(CMAKE_C_EXTENSIONS OFF)
elseif(CMAKE_COMPILER_IS_GNUCC OR CMAKE_C_COMPILER_ID MATCHES "Clang")
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c99")
endif()

find_package(anjay REQUIRED)

set(TUTORIAL_SOURCES
@@ -9,11 +16,4 @@ set(TUTORIAL_SOURCES
include_directories(${ANJAY_INCLUDE_DIRS})

add_executable(${PROJECT_NAME} ${TUTORIAL_SOURCES})
if(NOT CMAKE_VERSION VERSION_LESS 3.1)
set(CMAKE_C_STANDARD 99)
set(CMAKE_C_EXTENSIONS OFF)
elseif(CMAKE_COMPILER_IS_GNUCC OR CMAKE_C_COMPILER_ID MATCHES "Clang")
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c99")
endif()

target_link_libraries(${PROJECT_NAME} ${ANJAY_LIBRARIES_STATIC})
@@ -1,6 +1,13 @@
cmake_minimum_required(VERSION 2.8)
project(access-control C)

if(NOT CMAKE_VERSION VERSION_LESS 3.1)
set(CMAKE_C_STANDARD 99)
set(CMAKE_C_EXTENSIONS OFF)
elseif(CMAKE_COMPILER_IS_GNUCC OR CMAKE_C_COMPILER_ID MATCHES "Clang")
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c99")
endif()

find_package(anjay REQUIRED)

set(TUTORIAL_SOURCES
@@ -11,11 +18,4 @@ set(TUTORIAL_SOURCES
include_directories(${ANJAY_INCLUDE_DIRS})

add_executable(${PROJECT_NAME} ${TUTORIAL_SOURCES})
if(NOT CMAKE_VERSION VERSION_LESS 3.1)
set(CMAKE_C_STANDARD 99)
set(CMAKE_C_EXTENSIONS OFF)
elseif(CMAKE_COMPILER_IS_GNUCC OR CMAKE_C_COMPILER_ID MATCHES "Clang")
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c99")
endif()

target_link_libraries(${PROJECT_NAME} ${ANJAY_LIBRARIES_STATIC})
@@ -1,6 +1,13 @@
cmake_minimum_required(VERSION 2.8)
project(hello-world C)

if(NOT CMAKE_VERSION VERSION_LESS 3.1)
set(CMAKE_C_STANDARD 99)
set(CMAKE_C_EXTENSIONS OFF)
elseif(CMAKE_COMPILER_IS_GNUCC OR CMAKE_C_COMPILER_ID MATCHES "Clang")
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c99")
endif()

find_package(anjay REQUIRED)

set(TUTORIAL_SOURCES
@@ -9,11 +16,4 @@ set(TUTORIAL_SOURCES
include_directories(${ANJAY_INCLUDE_DIRS})

add_executable(${PROJECT_NAME} ${TUTORIAL_SOURCES})
if(NOT CMAKE_VERSION VERSION_LESS 3.1)
set(CMAKE_C_STANDARD 99)
set(CMAKE_C_EXTENSIONS OFF)
elseif(CMAKE_COMPILER_IS_GNUCC OR CMAKE_C_COMPILER_ID MATCHES "Clang")
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c99")
endif()

target_link_libraries(${PROJECT_NAME} ${ANJAY_LIBRARIES_STATIC})
@@ -1,6 +1,13 @@
cmake_minimum_required(VERSION 2.8)
project(object-registration C)

if(NOT CMAKE_VERSION VERSION_LESS 3.1)
set(CMAKE_C_STANDARD 99)
set(CMAKE_C_EXTENSIONS OFF)
elseif(CMAKE_COMPILER_IS_GNUCC OR CMAKE_C_COMPILER_ID MATCHES "Clang")
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c99")
endif()

find_package(anjay REQUIRED)

set(TUTORIAL_SOURCES
@@ -9,11 +16,4 @@ set(TUTORIAL_SOURCES
include_directories(${ANJAY_INCLUDE_DIRS})

add_executable(${PROJECT_NAME} ${TUTORIAL_SOURCES})
if(NOT CMAKE_VERSION VERSION_LESS 3.1)
set(CMAKE_C_STANDARD 99)
set(CMAKE_C_EXTENSIONS OFF)
elseif(CMAKE_COMPILER_IS_GNUCC OR CMAKE_C_COMPILER_ID MATCHES "Clang")
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c99")
endif()

target_link_libraries(${PROJECT_NAME} ${ANJAY_LIBRARIES_STATIC})
@@ -1,6 +1,13 @@
cmake_minimum_required(VERSION 2.8)
project(event-loop C)

if(NOT CMAKE_VERSION VERSION_LESS 3.1)
set(CMAKE_C_STANDARD 99)
set(CMAKE_C_EXTENSIONS OFF)
elseif(CMAKE_COMPILER_IS_GNUCC OR CMAKE_C_COMPILER_ID MATCHES "Clang")
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c99")
endif()

find_package(anjay REQUIRED)

set(TUTORIAL_SOURCES
@@ -9,11 +16,4 @@ set(TUTORIAL_SOURCES
include_directories(${ANJAY_INCLUDE_DIRS})

add_executable(${PROJECT_NAME} ${TUTORIAL_SOURCES})
if(NOT CMAKE_VERSION VERSION_LESS 3.1)
set(CMAKE_C_STANDARD 99)
set(CMAKE_C_EXTENSIONS OFF)
elseif(CMAKE_COMPILER_IS_GNUCC OR CMAKE_C_COMPILER_ID MATCHES "Clang")
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c99")
endif()

target_link_libraries(${PROJECT_NAME} ${ANJAY_LIBRARIES_STATIC})
@@ -1,18 +1,18 @@
cmake_minimum_required(VERSION 2.8)
project(bootstrap_awareness C)

find_package(anjay REQUIRED)

set(SOURCES src/main.c)

include_directories(${ANJAY_INCLUDE_DIRS})

add_executable(${PROJECT_NAME} ${SOURCES})
if(NOT CMAKE_VERSION VERSION_LESS 3.1)
set(CMAKE_C_STANDARD 99)
set(CMAKE_C_EXTENSIONS OFF)
elseif(CMAKE_COMPILER_IS_GNUCC OR CMAKE_C_COMPILER_ID MATCHES "Clang")
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c99")
endif()

find_package(anjay REQUIRED)

set(SOURCES src/main.c)

include_directories(${ANJAY_INCLUDE_DIRS})

add_executable(${PROJECT_NAME} ${SOURCES})
target_link_libraries(${PROJECT_NAME} ${ANJAY_LIBRARIES_STATIC})
@@ -1,6 +1,13 @@
cmake_minimum_required(VERSION 2.8)
project(multi-instance-dynamic C)

if(NOT CMAKE_VERSION VERSION_LESS 3.1)
set(CMAKE_C_STANDARD 99)
set(CMAKE_C_EXTENSIONS OFF)
elseif(CMAKE_COMPILER_IS_GNUCC OR CMAKE_C_COMPILER_ID MATCHES "Clang")
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c99")
endif()

find_package(anjay REQUIRED)

set(SOURCES
@@ -11,11 +18,4 @@ set(SOURCES
include_directories(${ANJAY_INCLUDE_DIRS})

add_executable(${PROJECT_NAME} ${SOURCES})
if(NOT CMAKE_VERSION VERSION_LESS 3.1)
set(CMAKE_C_STANDARD 99)
set(CMAKE_C_EXTENSIONS OFF)
elseif(CMAKE_COMPILER_IS_GNUCC OR CMAKE_C_COMPILER_ID MATCHES "Clang")
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c99")
endif()

target_link_libraries(${PROJECT_NAME} ${ANJAY_LIBRARIES_STATIC})
@@ -1,6 +1,13 @@
cmake_minimum_required(VERSION 2.8)
project(multi-instance-resources-dynamic C)

if(NOT CMAKE_VERSION VERSION_LESS 3.1)
set(CMAKE_C_STANDARD 99)
set(CMAKE_C_EXTENSIONS OFF)
elseif(CMAKE_COMPILER_IS_GNUCC OR CMAKE_C_COMPILER_ID MATCHES "Clang")
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c99")
endif()

find_package(anjay REQUIRED)

set(SOURCES
@@ -11,11 +18,4 @@ set(SOURCES
include_directories(${ANJAY_INCLUDE_DIRS})

add_executable(${PROJECT_NAME} ${SOURCES})
if(NOT CMAKE_VERSION VERSION_LESS 3.1)
set(CMAKE_C_STANDARD 99)
set(CMAKE_C_EXTENSIONS OFF)
elseif(CMAKE_COMPILER_IS_GNUCC OR CMAKE_C_COMPILER_ID MATCHES "Clang")
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c99")
endif()

target_link_libraries(${PROJECT_NAME} ${ANJAY_LIBRARIES_STATIC})
@@ -1,18 +1,18 @@
cmake_minimum_required(VERSION 2.8)
project(notifications C)

find_package(anjay REQUIRED)

set(SOURCES src/main.c)

include_directories(${ANJAY_INCLUDE_DIRS})

add_executable(${PROJECT_NAME} ${SOURCES})
if(NOT CMAKE_VERSION VERSION_LESS 3.1)
set(CMAKE_C_STANDARD 99)
set(CMAKE_C_EXTENSIONS OFF)
elseif(CMAKE_COMPILER_IS_GNUCC OR CMAKE_C_COMPILER_ID MATCHES "Clang")
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c99")
endif()

find_package(anjay REQUIRED)

set(SOURCES src/main.c)

include_directories(${ANJAY_INCLUDE_DIRS})

add_executable(${PROJECT_NAME} ${SOURCES})
target_link_libraries(${PROJECT_NAME} ${ANJAY_LIBRARIES_STATIC})
@@ -1,18 +1,18 @@
cmake_minimum_required(VERSION 2.8)
project(multi-instance-read-only-fixed C)

find_package(anjay REQUIRED)

set(SOURCES src/main.c)

include_directories(${ANJAY_INCLUDE_DIRS})

add_executable(${PROJECT_NAME} ${SOURCES})
if(NOT CMAKE_VERSION VERSION_LESS 3.1)
set(CMAKE_C_STANDARD 99)
set(CMAKE_C_EXTENSIONS OFF)
elseif(CMAKE_COMPILER_IS_GNUCC OR CMAKE_C_COMPILER_ID MATCHES "Clang")
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c99")
endif()

find_package(anjay REQUIRED)

set(SOURCES src/main.c)

include_directories(${ANJAY_INCLUDE_DIRS})

add_executable(${PROJECT_NAME} ${SOURCES})
target_link_libraries(${PROJECT_NAME} ${ANJAY_LIBRARIES_STATIC})
Oops, something went wrong.

0 comments on commit b647483

Please sign in to comment.
You can’t perform that action at this time.