From 83d91c24488dd19789314c235134d6361398e321 Mon Sep 17 00:00:00 2001
From: Christian Pointner <equinox@helsinki.at>
Date: Thu, 21 Jul 2011 04:37:38 +0000
Subject: addnote function should be working


diff --git a/rhimport-dn b/rhimport-dn
index fcfa7e9..0b95049 100755
--- a/rhimport-dn
+++ b/rhimport-dn
@@ -92,7 +92,7 @@ for my $entry ($feed->entries) {
 
       my $ff = File::Fetch->new(uri => $entry->enclosure->url);
       print $1 . ": downloading " . $entry->enclosure->url . " (" . $entry->enclosure->length . " Bytes) .. ";
-      $file = "test"; #$ff->fetch( to => '/tmp' ) or die $ff->error;
+      $file = $ff->fetch( to => '/tmp' ) or die $ff->error;
       print "ok\n";
       
       print "summary:\n" . $sum_title . "\n\n" . $sum_text . "\n";
@@ -103,6 +103,7 @@ for my $entry ($feed->entries) {
       local $SIG{CHLD} = 'DEFAULT';
       my $pid = open3($writer, $reader, $error, @PV_SCRIPT);
       print $writer $sum_title . "\n" . $sum_text;
+      close $writer;
       waitpid $pid, 0;
       my $out = join('', <$reader>);
       my $errstr = "";
@@ -123,8 +124,6 @@ for my $entry ($feed->entries) {
 (-e "$file") or die "file '$file' not found - donwload error?\n";
 print "will import $file to dropbox $dropbox (cart=$to_cart)\n\n";
 
-exit 0
-
 my $error_cb = sub {
   my ($text) = @_;
 
-- 
cgit v0.10.2