Since mydir is static (and hence survives the function call), if max_names is null (which happens if there are no aliases on the domain), then mydir has been closed, but mydir is not set to NULL. Hence when it does a second itteration of the function as qmailadmin will, it will segfault since it's not null, yet is closed.
I also attached my patch from earlier regarding forcing at least read/write permissions on the lock file, as I'm finding qmailadmin is creating them with no permissions (likely relating to a umask or something Debian related, so it's always best to force the permissions of the lock file).
Michael Krieger <[EMAIL PROTECTED]> wrote:
Seems there's a crash in qmailadmin/vpopmail still when adding only the first forward in a domain. The second works fine, but deleting the first and recreating it even shows an internal server error.
I'll have another look at the source, but I think there's still some bugs left to squash.