Commit 479c9882 authored by Rob Swindell's avatar Rob Swindell 💬
Browse files

Auto-detect/display UTF-8 encoded extended file descriptions

I noticed that the recent NASA "Earth Science Picture of the Day" files have had a DIZ with UTF-8 encoded apostrophe in it. <sigh>
parent 6d1b7f16
Pipeline #2691 passed with stage
in 9 minutes and 27 seconds
...@@ -101,7 +101,7 @@ void sbbs_t::showfileinfo(file_t* f, bool show_extdesc) ...@@ -101,7 +101,7 @@ void sbbs_t::showfileinfo(file_t* f, bool show_extdesc)
char* p = f->extdesc; char* p = f->extdesc;
SKIP_CRLF(p); SKIP_CRLF(p);
truncsp(p); truncsp(p);
putmsg(p, P_NOATCODES | P_CPM_EOF); putmsg(p, P_NOATCODES | P_CPM_EOF | P_AUTO_UTF8);
newline(); newline();
} }
if(f->size == -1) { if(f->size == -1) {
......
...@@ -437,7 +437,7 @@ bool sbbs_t::listfile(file_t* f, uint dirnum, const char *search, const char let ...@@ -437,7 +437,7 @@ bool sbbs_t::listfile(file_t* f, uint dirnum, const char *search, const char let
|| strnicmp(ext, "\0010", 2) == 0 || strnicmp(ext, "\0010", 2) == 0
|| strnicmp(ext, "\001W", 2) == 0) || strnicmp(ext, "\001W", 2) == 0)
ext += 2; ext += 2;
putmsg(ext, P_INDENT | P_NOATCODES | P_CPM_EOF | P_TRUNCATE); putmsg(ext, P_INDENT | P_NOATCODES | P_CPM_EOF | P_TRUNCATE | P_AUTO_UTF8);
} }
return true; return true;
} }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment