From 2f09cc7cd6c86ece05864055eca4ddfd78c03179 Mon Sep 17 00:00:00 2001 From: Martin Szulecki Date: Fri, 20 Mar 2009 11:00:59 +0100 Subject: Fix crashers due to bad data parsing and bad treeview cell sorting --- src/hylafax.cs | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'src/hylafax.cs') diff --git a/src/hylafax.cs b/src/hylafax.cs index 54ab63f..f54e7fe 100755 --- a/src/hylafax.cs +++ b/src/hylafax.cs @@ -700,20 +700,21 @@ namespace gfax { IPAddress ipaddr; int ipport; string jobfmt; - - write(mainstream, "PASV\n"); + + write(mainstream, "PASV\n"); string data = read(mainstream, mainclient); // dig out ip address and port for new connection ipaddr = get_ip_addr(data); ipport = get_ip_port(data); - + try { myclient.Connect(ipaddr, ipport); } catch (Exception e ) { Console.WriteLine(e.ToString()); // handle error here + return; } /* @@ -744,7 +745,7 @@ namespace gfax { data = read(mainstream, mainclient); } if (folder == "recvq") { - jobfmt = "\"%4p=N%1z=%28.28s=%7t=%f\""; + jobfmt = "\"%4p=N%1z=%28.28s=%-19Y=%f\""; write(mainstream, "RCVFMT "+jobfmt+"\n"); data = read(mainstream, mainclient); } @@ -815,7 +816,7 @@ namespace gfax { } else { gfax.asyncFolderMessageBuffer = ""; } - + StateObject state = new StateObject(); state.client = sock; state.readType = readType; -- cgit v1.1-32-gdbae