Improved C# version of GdbWrapper