evolution-rss r291 - in trunk: . src
- From: lucilanga svn gnome org
- To: svn-commits-list gnome org
- Subject: evolution-rss r291 - in trunk: . src
- Date: Sun, 15 Jun 2008 10:19:23 +0000 (UTC)
Author: lucilanga
Date: Sun Jun 15 10:19:23 2008
New Revision: 291
URL: http://svn.gnome.org/viewvc/evolution-rss?rev=291&view=rev
Log:
prefetch images
Modified:
trunk/TODO
trunk/src/rss.c
Modified: trunk/TODO
==============================================================================
--- trunk/TODO (original)
+++ trunk/TODO Sun Jun 15 10:19:23 2008
@@ -28,3 +28,4 @@
* when adding a feed as opml file offer to import (file detection)
* run-time migration function from text/evolution-rss-feed -> x-evolution/evolution-rss-feed
* test new proxy autehntification
+ * cache large feeds
Modified: trunk/src/rss.c
==============================================================================
--- trunk/src/rss.c (original)
+++ trunk/src/rss.c Sun Jun 15 10:19:23 2008
@@ -3900,9 +3900,9 @@
name = g_build_filename(tmpdir, g_path_get_basename(url), NULL);
g_free(template);
/* test for *loading* images*/
- gchar *iconfile = g_build_filename (EVOLUTION_ICONDIR,
+/* gchar *iconfile = g_build_filename (EVOLUTION_ICONDIR,
"rss-24.png",
- NULL);
+ NULL);*/
/* gchar *buf = g_malloc0(1024);
FILE *rf = fopen(iconfile, "rb");
fread(buf, 1, 1024, rf);
@@ -4088,7 +4088,8 @@
g_free(feed_dir);
FILE *fr = fopen(feed_name, "r");
- int fw = g_open (feed_name, O_WRONLY | O_CREAT| O_APPEND | O_BINARY, 0666);
+ FILE *fw = fopen(feed_name, "a+");
+ //int fw = g_open (feed_name, O_WRONLY | O_CREAT| O_APPEND | O_BINARY, 0666);
for (i=0; NULL != (el = g_array_index(item, xmlNodePtr, i)); i++)
{
@@ -4284,8 +4285,8 @@
{
if (fw)
{
- //fputs(feed, fw);
- write(fw,feed, strlen(feed));
+ fputs(feed, fw);
+ //write(fw,feed, strlen(feed));
// fsync(fw);
}
create_mail(CF);
@@ -4304,7 +4305,7 @@
out: g_free(sender);
if (fr) fclose(fr);
- if (fw) close(fw);
+ if (fw) fclose(fw);
g_free(feed_name);
return buf;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]