U.undosteps is nonzero. Also added optional parameter to avoid pushing undo info alltogether if desired.