summaryrefslogtreecommitdiff
path: root/lib/libalpm/util.c
diff options
context:
space:
mode:
authorAurelien Foret <aurelien@archlinux.org>2005-03-19 18:15:31 +0000
committerAurelien Foret <aurelien@archlinux.org>2005-03-19 18:15:31 +0000
commitbddea378b97088cdb303b4136f7e88f9130d0a2a (patch)
tree0a1dd44c34335a9d502388076ec676d940a5ab8d /lib/libalpm/util.c
parent2da0b2263ef80ab0b62dc81913a344c1bd6f92dd (diff)
downloadpacman-bddea378b97088cdb303b4136f7e88f9130d0a2a.tar.xz
Rework for fixed length strings
Diffstat (limited to 'lib/libalpm/util.c')
-rw-r--r--lib/libalpm/util.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/libalpm/util.c b/lib/libalpm/util.c
index 0c2e3360..053d7b98 100644
--- a/lib/libalpm/util.c
+++ b/lib/libalpm/util.c
@@ -144,13 +144,14 @@ char *_alpm_strtoupper(char *str)
char *_alpm_strtrim(char *str)
{
char *pch = str;
+
while(isspace(*pch)) {
pch++;
}
if(pch != str) {
memmove(str, pch, (strlen(pch) + 1));
}
-
+
pch = (char*)(str + (strlen(str) - 1));
while(isspace(*pch)) {
pch--;