Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/netbsd-3]: src/usr.bin/xinstall Pull up revision 1.89 (requested by luke...



details:   https://anonhg.NetBSD.org/src/rev/9291a5cba42a
branches:  netbsd-3
changeset: 575767:9291a5cba42a
user:      tron <tron%NetBSD.org@localhost>
date:      Tue May 10 12:43:53 2005 +0000

description:
Pull up revision 1.89 (requested by lukem in ticket #271):
strvis(3) encode the link=... argument in the metalog.
(mtree(8) already requires this.)

diffstat:

 usr.bin/xinstall/xinstall.c |  10 ++++++----
 1 files changed, 6 insertions(+), 4 deletions(-)

diffs (31 lines):

diff -r ad0212dc4201 -r 9291a5cba42a usr.bin/xinstall/xinstall.c
--- a/usr.bin/xinstall/xinstall.c       Tue May 10 12:42:02 2005 +0000
+++ b/usr.bin/xinstall/xinstall.c       Tue May 10 12:43:53 2005 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: xinstall.c,v 1.87.2.1 2005/05/10 12:42:02 tron Exp $   */
+/*     $NetBSD: xinstall.c,v 1.87.2.2 2005/05/10 12:43:53 tron Exp $   */
 
 /*
  * Copyright (c) 1987, 1993
@@ -46,7 +46,7 @@
 #if 0
 static char sccsid[] = "@(#)xinstall.c 8.1 (Berkeley) 7/21/93";
 #else
-__RCSID("$NetBSD: xinstall.c,v 1.87.2.1 2005/05/10 12:42:02 tron Exp $");
+__RCSID("$NetBSD: xinstall.c,v 1.87.2.2 2005/05/10 12:43:53 tron Exp $");
 #endif
 #endif /* not lint */
 
@@ -1057,8 +1057,10 @@
        p = buf;
                                                        /* print details */
        fprintf(metafp, ".%s%s type=%s mode=%#o", *p ? "/" : "", p, type, mode);
-       if (link)
-               fprintf(metafp, " link=%s", link);
+       if (link) {
+               strsvis(buf, link, VIS_CSTYLE, extra);  /* encode link */
+               fprintf(metafp, " link=%s", buf);
+       }
        if (owner)
                fprintf(metafp, " uname=%s", owner);
        if (group)



Home | Main Index | Thread Index | Old Index