improve type change error messages

This commit is contained in:
Michael Davidsaver
2020-05-19 10:03:02 -07:00
parent 2d075cbc1c
commit 027e590fba
3 changed files with 14 additions and 1 deletions
+1 -1
View File
@@ -218,7 +218,7 @@ struct ServerMonitorControl : public server::MonitorControlOp
Guard G(mon->lock);
if(val && mon->type && mon->type.get()!=Value::Helper::desc(val))
throw std::logic_error("Type change not allowed in post()");
throw std::logic_error("Type change not allowed in post(). Recommend pvxs::Value::cloneEmpty()");
if((mon->queue.size() < mon->limit) || force || !val) {
mon->queue.push_back(std::move(val));