Richard Pospesel pushed to branch tor-browser-102.5.0esr-12.5-1 at The Tor Project / Applications / Tor Browser
Commits:
81c5119b by Pier Angelo Vendrame at 2022-12-13T16:27:53+01:00
fixup! Bug 16940: After update, load local change notes.
Bug 41524: Read changelogs as UTF-8
- - - - -
1 changed file:
- browser/actors/AboutTBUpdateParent.jsm
Changes:
=====================================
browser/actors/AboutTBUpdateParent.jsm
=====================================
@@ -22,9 +22,9 @@ const kRequestUpdateMessageName = "FetchUpdateData";
* implementation.
*/
class AboutTBUpdateParent extends JSWindowActorParent {
- receiveMessage(aMessage) {
+ async receiveMessage(aMessage) {
if (aMessage.name == kRequestUpdateMessageName) {
- return this.releaseNoteInfo;
+ return this.getReleaseNoteInfo();
}
return undefined;
}
@@ -51,7 +51,7 @@ class AboutTBUpdateParent extends JSWindowActorParent {
// On Mac OS, when building with --enable-tor-browser-data-outside-app-dir
// to support Gatekeeper signing, the ChangeLog.txt file is located in
// TorBrowser.app/Contents/Resources/TorBrowser/Docs/.
- get releaseNoteInfo() {
+ async getReleaseNoteInfo() {
let info = { moreInfoURL: this.moreInfoURL };
try {
@@ -74,12 +74,7 @@ class AboutTBUpdateParent extends JSWindowActorParent {
f.append("Docs");
f.append("ChangeLog.txt");
- let fs = Cc["@mozilla.org/network/file-input-stream;1"].createInstance(
- Ci.nsIFileInputStream
- );
- fs.init(f, -1, 0, 0);
- let s = NetUtil.readInputStreamToString(fs, fs.available());
- fs.close();
+ let s = await IOUtils.readUTF8(f.path);
// Truncate at the first empty line.
s = s.replace(/[\r\n][\r\n][\s\S]*$/m, "");
View it on GitLab: https://gitlab.torproject.org/tpo/applications/tor-browser/-/commit/81c5119…
--
View it on GitLab: https://gitlab.torproject.org/tpo/applications/tor-browser/-/commit/81c5119…
You're receiving this email because of your account on gitlab.torproject.org.
Richard Pospesel deleted branch foo at The Tor Project / Applications / Tor Browser
--
You're receiving this email because of your account on gitlab.torproject.org.
Pier Angelo Vendrame deleted branch 41503-disable-restart-in-case-of-reboot-and-restore-in-case-of-crash at The Tor Project / Applications / Tor Browser
--
You're receiving this email because of your account on gitlab.torproject.org.