summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Jepp <tom@tomjepp.co.uk>2015-12-17 13:07:24 +0000
committerThomas Jepp <tom@tomjepp.co.uk>2015-12-17 13:07:24 +0000
commitf57a6d40973917e22c1d35c44e935b7e642954c8 (patch)
tree7c0b07c1389490a7856f0ed22bc8a3280fcb548d
parentf1f400ffc9bed893b58025c0dc383a34484ac950 (diff)
downloadvyatta-cfg-f57a6d40973917e22c1d35c44e935b7e642954c8.tar.gz
vyatta-cfg-f57a6d40973917e22c1d35c44e935b7e642954c8.zip
Replace dpkg version comparisions with strcmp.
-rw-r--r--src/cstore/cstore.cpp14
1 files changed, 1 insertions, 13 deletions
diff --git a/src/cstore/cstore.cpp b/src/cstore/cstore.cpp
index 485dcdb..85acbca 100644
--- a/src/cstore/cstore.cpp
+++ b/src/cstore/cstore.cpp
@@ -25,11 +25,6 @@
#include <sstream>
#include <memory>
-// for debian's version comparison algorithm
-#define APT_COMPATIBILITY 986
-#include <apt-pkg/version.h>
-#include <apt-pkg/debversion.h>
-
#include <cli_cstore.h>
#include <cstore/cstore.hpp>
#include <cstore/unionfs/cstore-unionfs.hpp>
@@ -2024,14 +2019,7 @@ Cstore::assert_internal(bool cond, const char *fmt, ...)
bool
Cstore::sort_func_deb_version(string a, string b)
{
- debVersioningSystem debVersioning;
-
- const char* A = a.c_str();
- const char* B = b.c_str();
- const char* Aend = A + a.length();
- const char* Bend = B + b.length();
-
- return debVersioning.DoCmpVersion(A, Aend, B, Bend) > 0;
+ return strcmp(a.c_str(), b.c_str()) > 0;
}
void