aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBaptiste Daroussin <bapt@FreeBSD.org>2017-03-01 21:35:25 +0000
committerBaptiste Daroussin <bapt@FreeBSD.org>2017-03-01 21:35:25 +0000
commit598ad972718c41f5438bf7654286bbce15c9cea1 (patch)
treebf9da996a3424602eec417f1cbad2ea02bb49590
parentbf3a47a7ab4802326f33d469e02f6632c12946e9 (diff)
downloadsrc-vendor/dma.tar.gz
src-vendor/dma.zip
Import dma snapshot from git 2017-02-10vendor/dma/20170210vendor/dma
The only change is: use basename to select executable identity PR: 216910 Submitted by: Andrej Ebert <andrej@ebert.su>
Notes
Notes: svn path=/vendor/dma/dist/; revision=314518 svn path=/vendor/dma/20170210/; revision=314519; tag=vendor/dma/20170210
-rw-r--r--dma.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/dma.c b/dma.c
index b87b20245583..e643e0f4ac9b 100644
--- a/dma.c
+++ b/dma.c
@@ -47,6 +47,7 @@
#include <errno.h>
#include <fcntl.h>
#include <inttypes.h>
+#include <libgen.h>
#include <paths.h>
#include <pwd.h>
#include <signal.h>
@@ -457,7 +458,7 @@ main(int argc, char **argv)
bzero(&queue, sizeof(queue));
LIST_INIT(&queue.queue);
- if (strcmp(argv[0], "mailq") == 0) {
+ if (strcmp(basename(argv[0]), "mailq") == 0) {
argv++; argc--;
showq = 1;
if (argc != 0)