svn commit: r314518 - vendor/dma/dist

Baptiste Daroussin bapt at FreeBSD.org
Wed Mar 1 21:35:26 UTC 2017


Author: bapt
Date: Wed Mar  1 21:35:25 2017
New Revision: 314518
URL: https://svnweb.freebsd.org/changeset/base/314518

Log:
  Import dma snapshot from git 2017-02-10
  
  The only change is:
  use basename to select executable identity
  
  PR:		216910
  Submitted by:	Andrej Ebert <andrej at ebert.su>

Modified:
  vendor/dma/dist/dma.c

Modified: vendor/dma/dist/dma.c
==============================================================================
--- vendor/dma/dist/dma.c	Wed Mar  1 21:31:44 2017	(r314517)
+++ vendor/dma/dist/dma.c	Wed Mar  1 21:35:25 2017	(r314518)
@@ -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)


More information about the svn-src-vendor mailing list