Added a wrapper for the UTF-8 decoding.
This commit is contained in:
parent
6227a91c01
commit
b7996b048b
|
@ -923,7 +923,7 @@ init_msg = function() {
|
||||||
|
|
||||||
/* Connection name/title */
|
/* Connection name/title */
|
||||||
name_length = ws.rQshift32();
|
name_length = ws.rQshift32();
|
||||||
fb_name = decodeURIComponent(escape(ws.rQshiftStr(name_length)));
|
fb_name = Util.decodeUTF8(ws.rQshiftStr(name_length));
|
||||||
conf.onDesktopName(that, fb_name);
|
conf.onDesktopName(that, fb_name);
|
||||||
|
|
||||||
if (conf.true_color && fb_name === "Intel(r) AMT KVM")
|
if (conf.true_color && fb_name === "Intel(r) AMT KVM")
|
||||||
|
|
|
@ -202,6 +202,14 @@ Util.conf_defaults = function(cfg, api, defaults, arr) {
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Decode from UTF-8
|
||||||
|
*/
|
||||||
|
Util.decodeUTF8 = function(utf8string) {
|
||||||
|
return decodeURIComponent(escape(utf8string));
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Cross-browser routines
|
* Cross-browser routines
|
||||||
|
|
Loading…
Reference in New Issue