X-Git-Url: http://nitlanguage.org diff --git a/src/nitdbg_client.nit b/src/nitdbg_client.nit index 3257c72..4b01ecd 100644 --- a/src/nitdbg_client.nit +++ b/src/nitdbg_client.nit @@ -89,7 +89,7 @@ class DebugClient fun read_command: String do - var buff = new Buffer + var buff = new FlatBuffer while debugger_connection.ready_to_read(40) do buff.append(debugger_connection.read) return buff.to_s end @@ -103,15 +103,12 @@ end # Create a tool context to handle options and paths var toolcontext = new ToolContext -toolcontext.process_options +toolcontext.tooldescription = "Usage: nitdbg_client [OPTION]...\nConnects to a nitdbg_server and controls it." +toolcontext.accept_no_arguments = true +toolcontext.process_options(args) var debug: DebugClient -if toolcontext.opt_help.value then - toolcontext.option_context.usage - return -end - # If the port value is not an Int between 0 and 65535 (Mandatory according to the norm) # Print the usage if toolcontext.opt_debug_port.value < 0 or toolcontext.opt_debug_port.value > 65535 then