Fixed set-maxdim