summaryrefslogtreecommitdiffstats
path: root/utils/genhdlist.c
diff options
context:
space:
mode:
Diffstat (limited to 'utils/genhdlist.c')
-rw-r--r--utils/genhdlist.c12
1 files changed, 2 insertions, 10 deletions
diff --git a/utils/genhdlist.c b/utils/genhdlist.c
index cf56a91f5..51e306d1d 100644
--- a/utils/genhdlist.c
+++ b/utils/genhdlist.c
@@ -443,17 +443,9 @@ int main(int argc, const char ** argv) {
nalloced += 5;
}
- p = b + strlen(b);
- i = 0;
- /* trim off two '.' worth of data */
- while (p > b && i < 2) {
- p--;
- if (*p == '.')
- i++;
- }
- *p = '\0';
-
len = strlen(b);
+ /* chop */
+ b[--len] = '\0';
depOrder[numpkgs] = malloc (len + 1);
strcpy (depOrder[numpkgs], b);
numpkgs++;