Mismatch of dimnames with ordinal data causes seg fault

If

dimnames = "sr"

is replaced by

dimnames = "val"

in the third last line of the script, then it runs fine without segfaulting. Yes, it's a scripting error, but we should catch it before it segfaults.

Automatically closed -- issue fixed for 2 weeks with no activity.