Improve scrollback file handling

- Properly use filesystem encoding
- Validate utf8 when loading (hopefully fixing crashes)
- Use Gio
- Handle Windows line endings
- Remove dead code
- Fix respecting max length of scrollback files
This commit is contained in:
Patrick Griffis
2016-01-31 15:13:18 -05:00
parent 089fe95a42
commit 650bddcfd1
3 changed files with 111 additions and 120 deletions

View File

@@ -377,7 +377,8 @@ typedef struct session
char channelkey[64]; /* XXX correct max length? */
int limit; /* channel user limit */
int logfd;
int scrollfd; /* scrollback filedes */
GFile *scrollfile; /* scrollback file */
int scrollwritten; /* number of lines written */
char lastnick[NICKLEN]; /* last nick you /msg'ed */