summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Wiegley <johnw@newartisans.com>2004-08-18 05:32:31 -0400
committerJohn Wiegley <johnw@newartisans.com>2004-08-18 05:32:31 -0400
commit41604e0ea65cb342aa05074bf39bbbc832c4c86a (patch)
treeb6914b6da8458b93df599dd8e690dfdef1adcbc2
parente1086a304001671d5a51df54b442c29559eaea15 (diff)
downloadfork-ledger-41604e0ea65cb342aa05074bf39bbbc832c4c86a.tar.gz
fork-ledger-41604e0ea65cb342aa05074bf39bbbc832c4c86a.tar.bz2
fork-ledger-41604e0ea65cb342aa05074bf39bbbc832c4c86a.zip
use now from datetime.cc
-rw-r--r--quotes.cc3
1 files changed, 1 insertions, 2 deletions
diff --git a/quotes.cc b/quotes.cc
index 4a21e9cb..0bc5779b 100644
--- a/quotes.cc
+++ b/quotes.cc
@@ -1,4 +1,5 @@
#include "quotes.h"
+#include "datetime.h"
#include <fstream>
@@ -9,8 +10,6 @@ void quotes_by_script::operator()(commodity_t * commodity,
const amount_t& price,
const std::time_t moment)
{
- std::time_t now = std::time(NULL); // the time of the query
-
if (! (commodity->flags & COMMODITY_STYLE_CONSULTED) &&
std::difftime(now, moment) < pricing_leeway &&
(! price || std::difftime(moment, date) > pricing_leeway)) {