aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJason Woodward2003-10-08 15:03:37 +0000
committerJason Woodward2003-10-08 15:03:37 +0000
commit74ecb490b53340c694542836f578059b43bc254b (patch)
tree88bfdf73dfe10e645107f948a40c387d8573f5c9
parentf4f2742de35173473ed6b7f14d2dd3cc894bdffa (diff)
downloadslapt-get-74ecb490b53340c694542836f578059b43bc254b.tar.gz
improved regex within package.h
-rw-r--r--ChangeLog3
-rw-r--r--src/package.h8
2 files changed, 6 insertions, 5 deletions
diff --git a/ChangeLog b/ChangeLog
index ec75605..235dd5e 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,7 +1,8 @@
-0.9.5d Oct 06, 2003
+0.9.5d Oct 08, 2003
* added initial slack-required for future dependancy support
* added lilo to example slapt-getrc exclude list
+ * improved regex within package.h
0.9.5c Oct 04, 2003
* removed bad free() in get_installed_pkgs()
diff --git a/src/package.h b/src/package.h
index 61329fa..6204638 100644
--- a/src/package.h
+++ b/src/package.h
@@ -19,14 +19,14 @@
#define MAX_PKG_ENTRIES 1300
#define MAX_NMATCH 4
#define MAX_PMATCH 4
-#define PKG_PARSE_REGEX "([a-zA-Z0-9-._/]+/)([a-zA-Z0-9-+_]+)-([a-zA-Z0-9-._]+).tgz$"
-#define PKG_NAME_PATTERN "^PACKAGE NAME: ([a-zA-Z0-9-+_]+)-([a-zA-Z0-9-._]+).tgz$"
+#define PKG_PARSE_REGEX "([a-zA-Z0-9._\\-\\/]+/)([a-zA-Z0-9+_\\-]+)-([a-zA-Z0-9._\\-]+).tgz$"
+#define PKG_NAME_PATTERN "^PACKAGE NAME: ([a-zA-Z0-9+_\\-]+)-([a-zA-Z0-9._\\-]+).tgz$"
#define PKG_LOCATION_PATTERN "^PACKAGE LOCATION: (.*)$"
#define PKG_SIZEC_PATTERN "^PACKAGE SIZE [(]+compressed[)]+: ([0-9]+) K$"
#define PKG_SIZEU_PATTERN "^PACKAGE SIZE [(]+uncompressed[)]+: ([0-9]+) K$"
#define PKG_LOG_DIR "/var/log/packages"
-#define PKG_LOG_PATTERN "^([a-zA-Z0-9-+_]+)-([a-zA-Z0-9-._]+)$"
-#define MD5SUM_REGEX "([a-zA-Z0-9]+)[ ]+([a-zA-Z0-9-._/]+/)([a-zA-Z0-9-+_]+)-([a-zA-Z0-9-._]+).tgz$"
+#define PKG_LOG_PATTERN "^([a-zA-Z0-9+_\\-]+)-([a-zA-Z0-9._\\-]+)$"
+#define MD5SUM_REGEX "([a-zA-Z0-9]+)[ ]+([a-zA-Z0-9._\\-\\/]+/)([a-zA-Z0-9+_\\-]+)-([a-zA-Z0-9._\\-]+).tgz$"
/*
* VARIABLE DEFINITIONS