diff --git a/apps/restconf/README.md b/apps/restconf/README.md index c8654187..dcce7567 100644 --- a/apps/restconf/README.md +++ b/apps/restconf/README.md @@ -9,6 +9,11 @@ Ensure www-data is member of the CLICON_SOCK_GROUP (default clicon). If not, add This implementation uses FastCGI, see http://www.mit.edu/~yandros/doc/specs/fcgi-spec.html. +Download and start nginx. For example on ubuntu: +``` + sudo apt install ngnix +``` + Define nginx config file: /etc/nginx/sites-available/default ``` server { @@ -68,6 +73,12 @@ olof@vandal> curl -G http://127.0.0.1/restconf/data/interfaces/interface/name=et curl -sX POST -d '{"interfaces":{"interface":{"name":"eth1","type":"eth","enabled":"true"}}}' http://localhost/restconf/data ``` +### Nginx Nchan for streams + +Restconf notification event streams needs a server-side push +package. Clixon has used Nchan (nchan.io) for this + +Download and install nchan, see nchan.io, Install section. ### Debugging diff --git a/lib/src/clixon_stream.c b/lib/src/clixon_stream.c index 25538b2f..31859ca3 100644 --- a/lib/src/clixon_stream.c +++ b/lib/src/clixon_stream.c @@ -114,6 +114,7 @@ stream_register(clicon_handle h, } /*! Delete complete notification event stream list (not just single stream) + * @param[in] es */ int stream_delete_all(event_stream_t *es) @@ -315,7 +316,6 @@ stream_notify_xml(clicon_handle h, * err; * @endcode * @see stream_notify_xml - * @see backend_notify */ int stream_notify(clicon_handle h, diff --git a/lib/src/clixon_yang.c b/lib/src/clixon_yang.c index 5b053217..874f3256 100644 --- a/lib/src/clixon_yang.c +++ b/lib/src/clixon_yang.c @@ -2471,7 +2471,7 @@ yang_spec_append(clicon_handle h, char *yang_revision) { int retval = -1; - yang_spec *yspec; + yang_spec *yspec = NULL; yang_spec *yspec0; yang_stmt *ym = NULL; /* module */