mirror of
https://github.com/mintty/wsltty.git
synced 2025-01-31 02:01:01 +00:00
fix file drag & drop by replacing /cygdrive to /mnt
This commit is contained in:
parent
a6d96ff1a2
commit
5340213c16
1
makefile
1
makefile
@ -35,6 +35,7 @@ mintty:
|
||||
$(wget) https://github.com/mintty/mintty/archive/master.zip
|
||||
mv master.zip mintty-master.zip
|
||||
unzip -o mintty-master.zip
|
||||
cd mintty-master; patch -p0 -i ../mintty_drag_drop_file.patch
|
||||
cd mintty-master/src; make LDFLAGS="-static -static-libgcc -s"
|
||||
mkdir -p bin
|
||||
cp mintty-master/bin/mintty.exe bin/
|
||||
|
19
mintty_drag_drop_file.patch
Normal file
19
mintty_drag_drop_file.patch
Normal file
@ -0,0 +1,19 @@
|
||||
--- src/charset.h.orig 2016-10-07 16:12:34.000000000 +0200
|
||||
+++ src/charset.h 2016-10-09 02:04:58.517284900 +0200
|
||||
@@ -79,7 +79,15 @@ extern bool widerange(xchar c);
|
||||
|
||||
static inline char *
|
||||
path_win_w_to_posix(const wchar * wp)
|
||||
-{ return cygwin_create_path(CCP_WIN_W_TO_POSIX, wp); }
|
||||
+{
|
||||
+ char *p;
|
||||
+ p = cygwin_create_path(CCP_WIN_W_TO_POSIX, wp);
|
||||
+ if (strncmp("/cygdrive/", p, 10) == 0) {
|
||||
+ strncpy(p, "/mnt/", 5);
|
||||
+ strcpy(p+5, p+10);
|
||||
+ }
|
||||
+ return p;
|
||||
+}
|
||||
|
||||
static inline wchar *
|
||||
path_posix_to_win_w(const char * p)
|
Loading…
x
Reference in New Issue
Block a user