|
Zbigniew Jędrzejewski-Szmek |
d3aa9f |
From f4574dc080b0bd9ef6898d954dc9e0e2b056b9c5 Mon Sep 17 00:00:00 2001
|
|
Zbigniew Jędrzejewski-Szmek |
d3aa9f |
From: =?UTF-8?q?Zbigniew=20J=C4=99drzejewski-Szmek?= <zbyszek@in.waw.pl>
|
|
Zbigniew Jędrzejewski-Szmek |
d3aa9f |
Date: Tue, 12 Apr 2022 20:42:32 +0200
|
|
Zbigniew Jędrzejewski-Szmek |
d3aa9f |
Subject: [PATCH 1/2] shared/install: fix crash when reenable is called without
|
|
Zbigniew Jędrzejewski-Szmek |
d3aa9f |
--root
|
|
Zbigniew Jędrzejewski-Szmek |
d3aa9f |
|
|
Zbigniew Jędrzejewski-Szmek |
d3aa9f |
---
|
|
Zbigniew Jędrzejewski-Szmek |
d3aa9f |
src/shared/install.c | 2 +-
|
|
Zbigniew Jędrzejewski-Szmek |
d3aa9f |
1 file changed, 1 insertion(+), 1 deletion(-)
|
|
Zbigniew Jędrzejewski-Szmek |
d3aa9f |
|
|
Zbigniew Jędrzejewski-Szmek |
d3aa9f |
diff --git a/src/shared/install.c b/src/shared/install.c
|
|
Zbigniew Jędrzejewski-Szmek |
d3aa9f |
index 58bccdcaa8..f7257c5ceb 100644
|
|
Zbigniew Jędrzejewski-Szmek |
d3aa9f |
--- a/src/shared/install.c
|
|
Zbigniew Jędrzejewski-Szmek |
d3aa9f |
+++ b/src/shared/install.c
|
|
Zbigniew Jędrzejewski-Szmek |
d3aa9f |
@@ -2825,7 +2825,7 @@ static int normalize_linked_files(
|
|
Zbigniew Jędrzejewski-Szmek |
d3aa9f |
return r;
|
|
Zbigniew Jędrzejewski-Szmek |
d3aa9f |
|
|
Zbigniew Jędrzejewski-Szmek |
d3aa9f |
const char *p = NULL;
|
|
Zbigniew Jędrzejewski-Szmek |
d3aa9f |
- if (i && i->path)
|
|
Zbigniew Jędrzejewski-Szmek |
d3aa9f |
+ if (i && i->path && i->root)
|
|
Zbigniew Jędrzejewski-Szmek |
d3aa9f |
/* Use startswith here, because we know that paths are normalized, and
|
|
Zbigniew Jędrzejewski-Szmek |
d3aa9f |
* path_startswith() would give us a relative path, but we need an absolute path
|
|
Zbigniew Jędrzejewski-Szmek |
d3aa9f |
* relative to i->root.
|