bug fixing, more ifdefs for REGULAR