diff --git a/baRSS/Core Data/Feed+Ext.m b/baRSS/Core Data/Feed+Ext.m
index d4bb232..a5b3447 100644
--- a/baRSS/Core Data/Feed+Ext.m
+++ b/baRSS/Core Data/Feed+Ext.m
@@ -196,7 +196,8 @@
if (self.articles.count == 0) {
img = [NSImage imageNamed:NSImageNameCaution];
} else if (self.hasIcon) {
- img = [[NSImage alloc] initByReferencingURL:[self iconPath]];
+ NSData* data = [[NSData alloc] initWithContentsOfURL:[self iconPath]];
+ img = [[NSImage alloc] initWithData:data];
} else {
img = [NSImage imageNamed:RSSImageDefaultRSSIcon];
}
diff --git a/baRSS/Feed Import/FaviconDownload.m b/baRSS/Feed Import/FaviconDownload.m
index 083f671..f61f5b3 100644
--- a/baRSS/Feed Import/FaviconDownload.m
+++ b/baRSS/Feed Import/FaviconDownload.m
@@ -147,7 +147,13 @@
return;
self.currentDownload = [[NSURLRequest requestWithURL:self.remoteURL] downloadTask:^(NSURL * _Nullable path, NSError * _Nullable error) {
if (error) path = nil; // will also nullify img
- NSImage *img = path ? [[NSImage alloc] initByReferencingURL:path] : nil;
+ NSImage *img;
+ if (path) {
+ NSData* data = [[NSData alloc] initWithContentsOfURL:path];
+ img = [[NSImage alloc] initWithData:data];
+ } else {
+ img = nil;
+ }
if (img.valid) {
// move image to temporary destination, otherwise dataTask: will delete it.
NSString *tmpFile = NSProcessInfo.processInfo.globallyUniqueString;
@@ -166,7 +172,8 @@
if (self.canceled)
return;
NSURL *path = self.fileURL;
- NSImage *img = [[NSImage alloc] initByReferencingURL:path];
+ NSData* data = [[NSData alloc] initWithContentsOfURL:path];
+ NSImage* img = [[NSImage alloc] initWithData:data];
if (!img.valid) { path = nil; img = nil; }
#if DEBUG && ENV_LOG_DOWNLOAD
printf("ICON %1.0fx%1.0f %s\n", img.size.width, img.size.height, self.remoteURL.absoluteString.UTF8String);
diff --git a/baRSS/Info.plist b/baRSS/Info.plist
index 52ced42..b2cdfec 100644
--- a/baRSS/Info.plist
+++ b/baRSS/Info.plist
@@ -70,7 +70,7 @@
CFBundleVersion
- 14603
+ 14620
LSApplicationCategoryType
public.app-category.news
LSMinimumSystemVersion
diff --git a/baRSS/Preferences/Feeds Tab/ModalFeedEdit.m b/baRSS/Preferences/Feeds Tab/ModalFeedEdit.m
index 0b1b3b4..f6f79ec 100644
--- a/baRSS/Preferences/Feeds Tab/ModalFeedEdit.m
+++ b/baRSS/Preferences/Feeds Tab/ModalFeedEdit.m
@@ -216,7 +216,13 @@
*/
- (void)faviconDownload:(FaviconDownload*)sender didFinish:(nullable NSURL*)path {
// Create image from favicon temporary file location or default icon if no favicon exists.
- NSImage *img = path ? [[NSImage alloc] initByReferencingURL:path] : [NSImage imageNamed:RSSImageDefaultRSSIcon];
+ NSImage *img;
+ if (path) {
+ NSData* data = [[NSData alloc] initWithContentsOfURL:path];
+ img = [[NSImage alloc] initWithData:data];
+ } else {
+ img = [NSImage imageNamed:RSSImageDefaultRSSIcon];
+ }
self.view.favicon.image = img;
self.faviconFile = path;
[self downloadComplete];
diff --git a/baRSS/Preferences/ModalSheet.m b/baRSS/Preferences/ModalSheet.m
index 05a6d44..fbcd03c 100644
--- a/baRSS/Preferences/ModalSheet.m
+++ b/baRSS/Preferences/ModalSheet.m
@@ -44,7 +44,7 @@
[content setFrameSize: NSMakeSize(w, h)];
// after content size, increase to window size
- w += 2 * PAD_WIN;
+ w += 2 * (NSInteger)PAD_WIN;
h += PAD_WIN + contentOffsetY; // the second PAD_WIN is already in contentOffsetY
NSWindowStyleMask style = NSWindowStyleMaskTitled | NSWindowStyleMaskResizable | NSWindowStyleMaskFullSizeContentView;