diff --git a/include/villas/path_destination.h b/include/villas/path_destination.h index 8cb9deb96..2a82baa64 100644 --- a/include/villas/path_destination.h +++ b/include/villas/path_destination.h @@ -30,12 +30,15 @@ #pragma once #include +#include /* Forward declarations */ struct vpath; struct sample; struct vpath_destination { + villas::Logger logger; + struct vnode *node; struct vpath *path; diff --git a/include/villas/path_source.h b/include/villas/path_source.h index 326ce576f..225972bb8 100644 --- a/include/villas/path_source.h +++ b/include/villas/path_source.h @@ -31,6 +31,7 @@ #include #include +#include /* Forward declarations */ struct vpath; @@ -42,6 +43,8 @@ enum PathSourceType { }; struct vpath_source { + Logger logger; + struct vnode *node; struct vpath *path; diff --git a/lib/path_destination.cpp b/lib/path_destination.cpp index a43b6dc47..8f81b9b91 100644 --- a/lib/path_destination.cpp +++ b/lib/path_destination.cpp @@ -32,10 +32,11 @@ using namespace villas; int path_destination_init(struct vpath_destination *pd, struct vpath *p, struct vnode *n) { + new (&pd->logger) Logger(logging.get("path:out")); + pd->node = n; pd->path = p; - vlist_push(&n->destinations, pd); return 0; diff --git a/lib/path_source.cpp b/lib/path_source.cpp index 1c4ac2a32..5ab8dc0e2 100644 --- a/lib/path_source.cpp +++ b/lib/path_source.cpp @@ -40,6 +40,8 @@ int path_source_init_master(struct vpath_source *ps, struct vpath *p, struct vno { int ret; + new (&pd->logger) Logger(logging.get("path:in")); + ps->node = n; ps->path = p; ps->masked = false;