Jacob points out that TS_EOL is broken in BINARY mode.
[u/mdw/putty] / config.c
index 922bfa1..536e94a 100644 (file)
--- a/config.c
+++ b/config.c
@@ -294,7 +294,7 @@ static void sessionsaver_handler(union control *ctrl, void *dlg,
            dlg_refresh(ssd->editbox, dlg);
            dlg_refresh(ssd->listbox, dlg);
        } else if (ctrl == ssd->delbutton) {
-           int i = dlg_listbox_index(ctrl, dlg);
+           int i = dlg_listbox_index(ssd->listbox, dlg);
            if (i <= 0) {
                dlg_beep(dlg);
            } else {