aboutsummaryrefslogtreecommitdiff
path: root/main.go
diff options
context:
space:
mode:
Diffstat (limited to 'main.go')
-rw-r--r--main.go9
1 files changed, 3 insertions, 6 deletions
diff --git a/main.go b/main.go
index 7a0749e..08640d1 100644
--- a/main.go
+++ b/main.go
@@ -5,7 +5,6 @@ import (
"fmt"
"net/url"
"os"
- "sync"
"github.com/Necoro/feed2imap-go/internal/feed"
"github.com/Necoro/feed2imap-go/internal/imap"
@@ -18,9 +17,7 @@ var cacheFile = flag.String("c", "feed.cache", "cache file")
var verbose = flag.Bool("v", false, "enable verbose output")
var debug = flag.Bool("d", false, "enable debug output")
-func processFeed(feed *feed.Feed, cfg *config.Config, client *imap.Client, wg *sync.WaitGroup) {
- defer wg.Done()
-
+func processFeed(feed *feed.Feed, cfg *config.Config, client *imap.Client) {
mails, err := feed.ToMails(cfg)
if err != nil {
log.Errorf("Processing items of feed %s: %s", feed.Name, err)
@@ -99,8 +96,8 @@ func run() error {
defer c.Disconnect()
- state.ForeachGo(func(f *feed.Feed, wg *sync.WaitGroup) {
- processFeed(f, cfg, c, wg)
+ state.ForeachGo(func(f *feed.Feed) {
+ processFeed(f, cfg, c)
})
if err = state.StoreCache(*cacheFile); err != nil {
pan>use cgit_httpscheme() for atom feedDiego Ongaro2-3/+6 2009-06-11add cgit_httpscheme() -> http:// or https://Diego Ongaro2-0/+12 2009-06-07Return http statuscode 404 on unknown branchLars Hjemli3-0/+6 2009-06-07Add head-include configuration option.Mark Lodato3-1/+6 2009-03-15CGIT 0.8.2.1v0.8.2.1Lars Hjemli1-1/+1 2009-03-15Fix doc-related glitches in Makefile and .gitignoreLars Hjemli2-1/+6 2009-03-15ui-snapshot: avoid segfault when no filename is specifiedLars Hjemli1-6/+17 2009-03-15fix segfault when displaying empty blobsEric Wong1-5/+8 2009-02-19Add support for HEAD requestsLars Hjemli2-0/+7 2009-02-19Add support for ETag in 'plain' viewLars Hjemli4-0/+5 2009-02-12ui-tree: escape ascii-text properly in hexdump viewLars Hjemli1-4/+9 2009-02-12Makefile: add doc-related targetsLars Hjemli1-2/+17