- *_base_path = dst->output.network.control->subdir[0] ?
- dst->output.network.control->subdir : NULL;
+ if (dst->output.network.control &&
+ dst->output.network.control->subdir[0]) {
+ *_base_path = dst->output.network.control->subdir;
+ } else {
+ *_base_path = NULL;
+ }