delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin-apps/2002/04/26/10:09:32

Mailing-List: contact cygwin-apps-help AT cygwin DOT com; run by ezmlm
Sender: cygwin-apps-owner AT cygwin DOT com
List-Subscribe: <mailto:cygwin-apps-subscribe AT cygwin DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin-apps/>
List-Post: <mailto:cygwin-apps AT cygwin DOT com>
List-Help: <mailto:cygwin-apps-help AT cygwin DOT com>, <http://sources.redhat.com/lists.html#faqs>
Mail-Followup-To: cygwin-apps AT cygwin DOT com
Delivered-To: mailing list cygwin-apps AT cygwin DOT com
Message-ID: <001601c1ed2b$f3424df0$42a18c09@wdg.uk.ibm.com>
From: "Max Bowsher" <maxb AT ukf DOT net>
To: "Corinna Vinschen" <cygwin-apps AT cygwin DOT com>
Subject: Minor bugfix for setup.exe - missing call to backslash() in desktop.cc
Date: Fri, 26 Apr 2002 15:09:16 +0100
MIME-Version: 1.0
X-Priority: 3
X-MSMail-Priority: Normal
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000
X-OriginalArrivalTime: 26 Apr 2002 14:09:16.0367 (UTC) FILETIME=[F3424DF0:01C1ED2B]
Note-from-DJ: This may be spam

This is a multi-part message in MIME format.

------=_NextPart_000_0013_01C1ED34.55009B70
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: 7bit

This adds a backslash() call to fix strange behaviour when creating the Cygwin
link on the start menu.
Currently, the link is created with name 'Programs/Cygwin/Cygwin Bash
Shell.lnk'. NB: those are slashes in the filename, not directory separators.
It's a minor bug, because once Windows notices this, it interprets the slashes,
and moves it into the intended directory structure - nevertheless, it would be
good to fix it. Accordingly, here are 1-liner patch and changelog. Patch is both
inline and attached for convenience, since it is so small.

My apologies for the ChangeLog not being indented properly - Outlook Express
eats tabs.

Max.

###BEGIN PATCH###
diff -mru cvssetup/desktop.cc setup/desktop.cc
--- cvssetup/desktop.cc Sun Mar  3 17:29:24 2002
+++ setup/desktop.cc Sun Mar  3 17:23:41 2002
@@ -143,7 +143,7 @@
 static void
 make_link (String const &linkpath, String const &title, String const &target)
 {
-  String fname = linkpath + "/" + title + ".lnk";
+  String fname = backslash(linkpath + "/" + title + ".lnk");

   if (_access (fname.cstr_oneuse(), 0) == 0)
     return;   /* already exists */
###END PATCH###

ChangeLog:
2002-04-26  Max Bowsher  <maxb AT ukf DOT net>

 * desktop.cc (make_link): Add backslash() for fname, so link is created
 in proper directory, rather than with slashes in its name.

Max.


------=_NextPart_000_0013_01C1ED34.55009B70
Content-Type: application/octet-stream;
	name="start-menu-shortcut-slashfix.patch"
Content-Transfer-Encoding: quoted-printable
Content-Disposition: attachment;
	filename="start-menu-shortcut-slashfix.patch"

diff -mru cvssetup/desktop.cc setup/desktop.cc=0A=
--- cvssetup/desktop.cc	Sun Mar  3 17:29:24 2002=0A=
+++ setup/desktop.cc	Sun Mar  3 17:23:41 2002=0A=
@@ -143,7 +143,7 @@=0A=
 static void=0A=
 make_link (String const &linkpath, String const &title, String const =
&target)=0A=
 {=0A=
-  String fname =3D linkpath + "/" + title + ".lnk";=0A=
+  String fname =3D backslash(linkpath + "/" + title + ".lnk");=0A=
 =0A=
   if (_access (fname.cstr_oneuse(), 0) =3D=3D 0)=0A=
     return;			/* already exists */=0A=

------=_NextPart_000_0013_01C1ED34.55009B70--

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019