aboutsummaryrefslogtreecommitdiff
path: root/externals/grill/vasp/source/ops_search.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'externals/grill/vasp/source/ops_search.cpp')
-rw-r--r--externals/grill/vasp/source/ops_search.cpp9
1 files changed, 6 insertions, 3 deletions
diff --git a/externals/grill/vasp/source/ops_search.cpp b/externals/grill/vasp/source/ops_search.cpp
index d805437d..bc7c1345 100644
--- a/externals/grill/vasp/source/ops_search.cpp
+++ b/externals/grill/vasp/source/ops_search.cpp
@@ -79,12 +79,15 @@ BL VecOp::d_search(OpParam &p)
Vasp *VaspOp::m_search(OpParam &p,CVasp &src,const Argument &arg,CVasp *dst,BL st)
{
Vasp *ret = NULL;
- if(src.Vectors() > 1)
- post("%s - More than one vector in vasp!",p.opName());
+ if(src.Vectors() != 1)
+ post("%s - Need exactly one vector in vasp!",p.opName());
else if(arg.CanbeFloat() || (arg.IsList() && arg.GetList().Count() >= 1)) {
I fr = src.Frames();
I o = src.Vector(0).Offset();
- I sz = src.Buffer(0)->Frames();
+
+ VBuffer *buf = src.Buffer(0);
+ I sz = buf->Frames();
+ delete buf;
CVasp all(src);
if(st) {