Index: src/commands.mm ================================================================== --- src/commands.mm +++ src/commands.mm @@ -234,11 +234,11 @@ __kindof Identifier *identifier = identifiers[c]; if (identifier == nil) { @try { val = (int)[c longLongValueWithBase:0]; } @catch (OFInvalidFormatException *e) { - conoutf(@"unknown command: %s", c); + conoutf(@"unknown command: %@", c); } } else { if ([identifier isKindOfClass:[Command class]]) { // game defined commands use very Index: src/console.mm ================================================================== --- src/console.mm +++ src/console.mm @@ -189,18 +189,19 @@ switch (code) { case SDLK_RETURN: break; case SDLK_BACKSPACE: - case SDLK_LEFT: { - [commandbuf - deleteCharactersInRange: - OFMakeRange(commandbuf.length - 1, 1)]; + case SDLK_LEFT: + if (commandbuf.length > 0) + [commandbuf + deleteCharactersInRange: + OFMakeRange( + commandbuf.length - 1, 1)]; resetcomplete(); break; - } case SDLK_UP: if (histpos) commandbuf = [vhistory[--histpos] mutableCopy];