From ff7ff3b55b4d2f41b444cf8d0d823e69d9cb56c9 Mon Sep 17 00:00:00 2001 From: orignal Date: Wed, 24 Dec 2014 07:48:18 -0500 Subject: [PATCH] check status code 304 --- AddressBook.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/AddressBook.cpp b/AddressBook.cpp index a650aaff..799b3f75 100644 --- a/AddressBook.cpp +++ b/AddressBook.cpp @@ -420,7 +420,7 @@ namespace client void AddressBookSubscription::Request () { // must be run in separate thread - LogPrint (eLogInfo, "Downloading hosts from ", m_Link); + LogPrint (eLogInfo, "Downloading hosts from ", m_Link, " ETag: ", m_Etag, " Last-Modified: ", m_LastModified); bool success = false; i2p::util::http::url u (m_Link); i2p::data::IdentHash ident; @@ -510,6 +510,11 @@ namespace client } } } + else if (status == 304) + { + success = true; + LogPrint (eLogInfo, "No updates from ", m_Link); + } else LogPrint (eLogWarning, "Adressbook HTTP response ", status); }