mirror of
https://github.com/Telecominfraproject/wlan-ap.git
synced 2025-12-20 10:51:27 +00:00
This patch will reslove command manager crash issue and also add support for deleting the lingering entries in the command state table Signed-off-by: Nagendrababu <nagendrababu.bonkuri@connectus.ai>
46 lines
1.7 KiB
Diff
46 lines
1.7 KiB
Diff
--- a/src/lib/ovsdb/src/ovsdb_sync_api.c
|
|
+++ b/src/lib/ovsdb/src/ovsdb_sync_api.c
|
|
@@ -62,6 +62,10 @@ json_t* ovsdb_where_uuid(const char *col
|
|
{
|
|
return ovsdb_tran_cond(OCLM_UUID, column, OFUNC_EQ, uuid);
|
|
}
|
|
+json_t* ovsdb_where_timestamp(const char *column, int *timestamp)
|
|
+{
|
|
+ return ovsdb_tran_cond(OCLM_INT, column, OFUNC_EQ, timestamp);
|
|
+}
|
|
|
|
/* ovsdb_where_multi() combines multiple ovsdb_where_*() conditions
|
|
* Example:
|
|
--- a/src/lib/ovsdb/inc/ovsdb_sync.h
|
|
+++ b/src/lib/ovsdb/inc/ovsdb_sync.h
|
|
@@ -38,6 +38,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBI
|
|
json_t* ovsdb_where_simple(const char *column, const char *value);
|
|
json_t* ovsdb_where_simple_typed(const char *column, const void *value, ovsdb_col_t col_type);
|
|
json_t* ovsdb_where_uuid(const char *column, const char *uuid);
|
|
+json_t* ovsdb_where_timestamp(const char *column, int *timestamp);
|
|
json_t* ovsdb_where_multi(json_t *where, ...);
|
|
json_t* ovsdb_mutation(const char *column, json_t *mutation, json_t *value);
|
|
int ovsdb_get_update_result_count(json_t *result, const char *table, const char *oper);
|
|
--- a/src/lib/ovsdb/src/ovsdb_method.c
|
|
+++ b/src/lib/ovsdb/src/ovsdb_method.c
|
|
@@ -677,8 +677,9 @@ json_t * ovsdb_tran_cond(ovsdb_col_t col
|
|
ovsdb_func_t func,
|
|
const void * value)
|
|
{
|
|
- const json_int_t *jint = value;
|
|
+ // const json_int_t *jint = value;
|
|
json_t * jval = NULL;
|
|
+ const int *tsmp = value;
|
|
json_t * jtop;
|
|
|
|
/* wrap-up into additional array */
|
|
@@ -701,7 +702,7 @@ json_t * ovsdb_tran_cond(ovsdb_col_t col
|
|
break;
|
|
|
|
case OCLM_INT:
|
|
- jval = json_integer(*jint);
|
|
+ jval = json_integer(*tsmp);
|
|
break;
|
|
|
|
default:
|