summaryrefslogtreecommitdiff
path: root/openssh-8.0p1-keygen-strip-doseol.patch
diff options
context:
space:
mode:
authorCoprDistGit <infra@openeuler.org>2023-10-02 01:13:25 +0000
committerCoprDistGit <infra@openeuler.org>2023-10-02 01:13:25 +0000
commitf38978765535e8c844371dbcd8e2ae1ace135e08 (patch)
tree8f6f73cc41ec340be45959fae67da4c6abec1e21 /openssh-8.0p1-keygen-strip-doseol.patch
parent151bd95e0af0e9382ca9065b0d6cc6d62f1ac794 (diff)
automatic import of opensshopeneuler20.03
Diffstat (limited to 'openssh-8.0p1-keygen-strip-doseol.patch')
-rw-r--r--openssh-8.0p1-keygen-strip-doseol.patch12
1 files changed, 12 insertions, 0 deletions
diff --git a/openssh-8.0p1-keygen-strip-doseol.patch b/openssh-8.0p1-keygen-strip-doseol.patch
new file mode 100644
index 0000000..3117a7a
--- /dev/null
+++ b/openssh-8.0p1-keygen-strip-doseol.patch
@@ -0,0 +1,12 @@
+diff -up openssh-8.0p1/ssh-keygen.c.strip-doseol openssh-8.0p1/ssh-keygen.c
+--- openssh-8.0p1/ssh-keygen.c.strip-doseol 2021-03-18 17:41:34.472404994 +0100
++++ openssh-8.0p1/ssh-keygen.c 2021-03-18 17:41:55.255538761 +0100
+@@ -901,7 +901,7 @@ do_fingerprint(struct passwd *pw)
+ while (getline(&line, &linesize, f) != -1) {
+ lnum++;
+ cp = line;
+- cp[strcspn(cp, "\n")] = '\0';
++ cp[strcspn(cp, "\r\n")] = '\0';
+ /* Trim leading space and comments */
+ cp = line + strspn(line, " \t");
+ if (*cp == '#' || *cp == '\0')