File: addons.patch

package info (click to toggle)
wine 4.0-2
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 209,096 kB
  • sloc: ansic: 2,906,412; perl: 18,817; yacc: 15,629; makefile: 9,134; objc: 6,543; lex: 4,315; python: 1,786; cpp: 1,042; sh: 771; java: 742; xml: 557; awk: 69; cs: 17
file content (29 lines) | stat: -rw-r--r-- 1,197 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
description: adjust search paths for addon installers
author: Michael Gilbert <mgilbert@debian.org>
author: Jens Reyer <jre.winesim@gmail.com>

--- a/dlls/appwiz.cpl/addons.c
+++ b/dlls/appwiz.cpl/addons.c
@@ -212,8 +212,6 @@ static enum install_res install_from_uni
         return INSTALL_FAILED;
 
     memcpy(file_path, dir, len);
-    if(len && file_path[len-1] != '/' && file_path[len-1] != '\\')
-        file_path[len++] = '/';
     if(*subdir) {
         strcpy(file_path+len, subdir);
         len += strlen(subdir);
@@ -323,11 +321,12 @@ static enum install_res install_from_def
         return INSTALL_NEXT;
     }
 
+    package_dir = "/usr/share/wine-";
     ret = install_from_unix_file(package_dir, addon->subdir_name, addon->file_name);
     heap_free(dir_buf);
 
     if (ret == INSTALL_NEXT)
-        ret = install_from_unix_file(INSTALL_DATADIR "/wine/", addon->subdir_name, addon->file_name);
+        ret = install_from_unix_file(INSTALL_DATADIR "/", addon->subdir_name, addon->file_name);
     if (ret == INSTALL_NEXT && strcmp(INSTALL_DATADIR, "/usr/share"))
         ret = install_from_unix_file("/usr/share/wine/", addon->subdir_name, addon->file_name);
     return ret;