Unverified Commit 65f9c1ab authored by Axel Kohlmeyer's avatar Axel Kohlmeyer
Browse files

bugfix: reorder instructions

parent 0748b124
Loading
Loading
Loading
Loading
+4 −3
Original line number Diff line number Diff line
@@ -4221,13 +4221,14 @@ int Variable::special_function(char *word, char *contents, Tree **tree,
      if (eval_in_progress[ivar])
        print_var_error(FLERR,"Variable has circular dependency",ivar);

      if ((method == AVE) && (nvec == 0))
        print_var_error(FLERR,"Cannot compute average of empty vector",ivar);

      double *vec;
      nvec = compute_vector(ivar,&vec);
      nstride = 1;

      if ((method == AVE) && (nvec == 0))
        print_var_error(FLERR,"Cannot compute average of empty vector",ivar);


    } else print_var_error(FLERR,"Invalid special function in "
                           "variable formula",ivar);