+Tue Jul 2 12:29:52 CEST 2002 Wichert Akkerman <wichert@deephackmode.org>
+
+ * Merge from HEAD:
+ + lib/myopt: check for malloc failure and actually look in $HOME for
+ file instead of looking in confdir twice
+
Tue Jul 2 10:20:40 CEST 2002 Wichert Akkerman <wichert@deephackmode.org>
* debian/rules: cp instead of mv since we need files for both dpkg
+dpkg (1.10.2) unstable; urgency=low
+
+ * Make configuration files in $HOME work again
+
+ -- Wichert Akkerman <wakkerma@debian.org> UNRELEASED
+
dpkg (1.10.1) unstable; urgency=low
* Add conflict with dpkg-iasearch which intruded on our namespace.
Closes: Bug#150739
* Move dpkg.cfg and dselect.cfg manpages into dpkg package. Closes: Bug#132901
- -- Wichert Akkerman <wakkerma@debian.org> Tue, 2 Jul 2002 10:30:34 +0200
+ -- Wichert Akkerman <wakkerma@debian.org> Tue, 2 Jul 2002 12:34:07 +0200
dpkg (1.10) unstable; urgency=low
* myopt.c - my very own option parsing
*
* Copyright (C) 1994,1995 Ian Jackson <ian@chiark.greenend.org.uk>
- * Copyright (C) 2000 Wichert Akkerman <wakkerma@debian.org>
+ * Copyright (C) 2000,2002 Wichert Akkerman <wichert@deephackmode.org>
*
* This is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as
int l1, l2;
l1 = strlen(CONFIGDIR "/.cfg") + strlen(prog);
file = malloc(l1 + 1);
+ if (file==NULL) ohshite(_("Error allocating memory for cfgfilename"));
sprintf(file, CONFIGDIR "/%s.cfg", prog);
myfileopt(file, cmdinfos);
if ((home = getenv("HOME")) != NULL) {
- l2 = strlen(home) + strlen("/.cfg") + strlen(prog);
+ l2 = strlen(home) + 1 + strlen("/.cfg") + strlen(prog);
if (l2 > l1) {
free(file);
file = malloc(l2 + 1);
- l1 = l2;
+ if (file==NULL) ohshite(_("Error allocating memory for cfgfilename"));
}
+ sprintf(file, "%s/.%s.cfg", home, prog);
myfileopt(file, cmdinfos);
}
free(file);