aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTim Keller <tjk@tjkeller.xyz>2025-12-15 20:04:33 -0600
committerTim Keller <tjk@tjkeller.xyz>2025-12-15 20:04:33 -0600
commit15b710c37770c045a45cecacf267ca0f452d1eb1 (patch)
tree84267d748c0e45fe79cd97e3cb4b0dfcb39894d4
parent0bb1215a02ba21c836087cd6a04817e2f05aced4 (diff)
downloadst-15b710c37770c045a45cecacf267ca0f452d1eb1.tar.xz
st-15b710c37770c045a45cecacf267ca0f452d1eb1.zip
update xdnd patch to check for file:// prefix before removing it which is already upstream
-rw-r--r--x.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/x.c b/x.c
index 71a95ac..7ca1b41 100644
--- a/x.c
+++ b/x.c
@@ -729,7 +729,9 @@ xdndpastedata(char *data)
t = strtok(data, "\n\r");
while(t != NULL) {
- t += 7; /* remove 'file://' prefix */
+ /* remove 'file://' prefix if it exists */
+ if (strncmp(data, "file://", 7) == 0)
+ t += 7;
i += xdndurldecode(t, pastedata + i);
t = strtok(NULL, "\n\r");
}