fixing problem with reference shorter than NUMCHAR