Code style: Replace tab with space.
diff --git a/ndn-cpp/c/encoding/binary-xml-forwarding-entry.h b/ndn-cpp/c/encoding/binary-xml-forwarding-entry.h
index 4a23371..b08f292 100644
--- a/ndn-cpp/c/encoding/binary-xml-forwarding-entry.h
+++ b/ndn-cpp/c/encoding/binary-xml-forwarding-entry.h
@@ -5,14 +5,14 @@
*/
#ifndef NDN_BINARY_XML_FORWARDING_ENTRY_H
-#define NDN_BINARY_XML_FORWARDING_ENTRY_H
+#define NDN_BINARY_XML_FORWARDING_ENTRY_H
#include "../errors.h"
#include "../forwarding-entry.h"
#include "binary-xml-encoder.h"
#include "binary-xml-decoder.h"
-#ifdef __cplusplus
+#ifdef __cplusplus
extern "C" {
#endif
@@ -32,7 +32,7 @@
*/
ndn_Error ndn_decodeBinaryXmlForwardingEntry(struct ndn_ForwardingEntry *forwardingEntry, struct ndn_BinaryXmlDecoder *decoder);
-#ifdef __cplusplus
+#ifdef __cplusplus
}
#endif
diff --git a/ndn-cpp/c/name.c b/ndn-cpp/c/name.c
index d6864e9..355636d 100644
--- a/ndn-cpp/c/name.c
+++ b/ndn-cpp/c/name.c
@@ -37,11 +37,11 @@
int ndn_Name_match(struct ndn_Name *self, struct ndn_Name *name)
{
- // This name is longer than the name we are checking it against.
- if (self->nComponents > name->nComponents)
+ // This name is longer than the name we are checking it against.
+ if (self->nComponents > name->nComponents)
return 0;
- // Check if at least one of given components doesn't match.
+ // Check if at least one of given components doesn't match.
size_t i;
for (i = 0; i < self->nComponents; ++i) {
struct ndn_NameComponent *selfComponent = self->components + i;
@@ -52,5 +52,5 @@
return 0;
}
- return 1;
+ return 1;
}
diff --git a/ndn-cpp/c/util/blob.h b/ndn-cpp/c/util/blob.h
index 18bcd03..8d1f784 100644
--- a/ndn-cpp/c/util/blob.h
+++ b/ndn-cpp/c/util/blob.h
@@ -5,11 +5,11 @@
*/
#ifndef NDN_BLOB_H
-#define NDN_BLOB_H
+#define NDN_BLOB_H
#include <ndn-cpp/c/common.h>
-#ifdef __cplusplus
+#ifdef __cplusplus
extern "C" {
#endif
@@ -33,7 +33,7 @@
self->length = length;
}
-#ifdef __cplusplus
+#ifdef __cplusplus
}
#endif
diff --git a/ndn-cpp/encoding/oid.cpp b/ndn-cpp/encoding/oid.cpp
index 236e420..db1fbc3 100644
--- a/ndn-cpp/encoding/oid.cpp
+++ b/ndn-cpp/encoding/oid.cpp
@@ -26,7 +26,7 @@
pos = str.find_first_of('.', pos);
if(pos == string::npos)
- break;
+ break;
oid_.push_back(atoi(str.substr(ppos, pos - ppos).c_str()));
diff --git a/ndn-cpp/interest.cpp b/ndn-cpp/interest.cpp
index ceeffcd..92fe972 100644
--- a/ndn-cpp/interest.cpp
+++ b/ndn-cpp/interest.cpp
@@ -52,8 +52,8 @@
string
Exclude::toUri() const
{
- if (entries_.size() == 0)
- return "";
+ if (entries_.size() == 0)
+ return "";
ostringstream result;
for (unsigned i = 0; i < entries_.size(); ++i) {
diff --git a/ndn-cpp/name.cpp b/ndn-cpp/name.cpp
index c9b5e7f..6f42635 100644
--- a/ndn-cpp/name.cpp
+++ b/ndn-cpp/name.cpp
@@ -323,7 +323,7 @@
bool
Name::equals(const Name& name) const
{
- if (components_.size() != name.components_.size())
+ if (components_.size() != name.components_.size())
return false;
for (size_t i = 0; i < components_.size(); ++i) {
@@ -331,7 +331,7 @@
return false;
}
- return true;
+ return true;
}
bool
@@ -339,17 +339,17 @@
{
// Imitate ndn_Name_match.
- // This name is longer than the name we are checking it against.
- if (components_.size() > name.components_.size())
+ // This name is longer than the name we are checking it against.
+ if (components_.size() > name.components_.size())
return false;
- // Check if at least one of given components doesn't match.
+ // Check if at least one of given components doesn't match.
for (size_t i = 0; i < components_.size(); ++i) {
if (*components_[i].getValue() != *name.components_[i].getValue())
return false;
}
- return true;
+ return true;
}
void
diff --git a/ndn-cpp/node.cpp b/ndn-cpp/node.cpp
index c145d50..1ce715c 100644
--- a/ndn-cpp/node.cpp
+++ b/ndn-cpp/node.cpp
@@ -306,17 +306,17 @@
int iResult = -1;
- for (size_t i = 0; i < pendingInterestTable_.size(); ++i) {
- if (ndn_Interest_matchesName((struct ndn_Interest *)&pendingInterestTable_[i]->getInterestStruct(), &nameStruct)) {
+ for (size_t i = 0; i < pendingInterestTable_.size(); ++i) {
+ if (ndn_Interest_matchesName((struct ndn_Interest *)&pendingInterestTable_[i]->getInterestStruct(), &nameStruct)) {
if (iResult < 0 ||
pendingInterestTable_[i]->getInterestStruct().name.nComponents >
pendingInterestTable_[iResult]->getInterestStruct().name.nComponents)
// Update to the longer match.
iResult = i;
}
- }
+ }
- return iResult;
+ return iResult;
}
Node::RegisteredPrefix*
@@ -324,17 +324,17 @@
{
int iResult = -1;
- for (size_t i = 0; i < registeredPrefixTable_.size(); ++i) {
- if (registeredPrefixTable_[i]->getPrefix()->match(name)) {
+ for (size_t i = 0; i < registeredPrefixTable_.size(); ++i) {
+ if (registeredPrefixTable_[i]->getPrefix()->match(name)) {
if (iResult < 0 ||
registeredPrefixTable_[i]->getPrefix()->getComponentCount() > registeredPrefixTable_[iResult]->getPrefix()->getComponentCount())
// Update to the longer match.
iResult = i;
}
- }
+ }
if (iResult >= 0)
- return registeredPrefixTable_[iResult].get();
+ return registeredPrefixTable_[iResult].get();
else
return 0;
}
diff --git a/ndn-cpp/util/changed-event.hpp b/ndn-cpp/util/changed-event.hpp
index 71be366..e20f3d5 100644
--- a/ndn-cpp/util/changed-event.hpp
+++ b/ndn-cpp/util/changed-event.hpp
@@ -6,7 +6,7 @@
*/
#ifndef NDN_CHANGED_EVENT_HPP
-#define NDN_CHANGED_EVENT_HPP
+#define NDN_CHANGED_EVENT_HPP
#include <vector>
#include <ndn-cpp/common.hpp>
diff --git a/ndn-cpp/util/logging.hpp b/ndn-cpp/util/logging.hpp
index f1afe72..b668133 100644
--- a/ndn-cpp/util/logging.hpp
+++ b/ndn-cpp/util/logging.hpp
@@ -7,7 +7,7 @@
*/
#ifndef NDN_LOGGING_HPP
-#define NDN_LOGGING_HPP
+#define NDN_LOGGING_HPP
#include <ndn-cpp//common.hpp>