diff options
author | dtucker@openbsd.org <dtucker@openbsd.org> | 2017-03-06 00:44:51 +0000 |
---|---|---|
committer | Darren Tucker <dtucker@zip.com.au> | 2017-03-06 13:17:31 +1100 |
commit | d072370793f1a20f01ad827ba8fcd3b8f2c46165 (patch) | |
tree | 9617ec73528314a1db49cf110f19c20a3acd4b6c /ssh-keygen.c | |
parent | 12d3767ba4c84c32150cbe6ff6494498780f12c9 (diff) |
upstream commit
linenum is unsigned long so use %lu in log formats. ok
deraadt@
Upstream-ID: 9dc582d9bb887ebe0164e030d619fc20b1a4ea08
Diffstat (limited to 'ssh-keygen.c')
-rw-r--r-- | ssh-keygen.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/ssh-keygen.c b/ssh-keygen.c index 2259b340d..ca94fe44f 100644 --- a/ssh-keygen.c +++ b/ssh-keygen.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: ssh-keygen.c,v 1.296 2017/03/03 06:13:11 djm Exp $ */ | 1 | /* $OpenBSD: ssh-keygen.c,v 1.297 2017/03/06 00:44:51 dtucker Exp $ */ |
2 | /* | 2 | /* |
3 | * Author: Tatu Ylonen <ylo@cs.hut.fi> | 3 | * Author: Tatu Ylonen <ylo@cs.hut.fi> |
4 | * Copyright (c) 1994 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland | 4 | * Copyright (c) 1994 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland |
@@ -1096,7 +1096,7 @@ known_hosts_hash(struct hostkey_foreach_line *l, void *_ctx) | |||
1096 | if (was_hashed || has_wild || l->marker != MRK_NONE) { | 1096 | if (was_hashed || has_wild || l->marker != MRK_NONE) { |
1097 | fprintf(ctx->out, "%s\n", l->line); | 1097 | fprintf(ctx->out, "%s\n", l->line); |
1098 | if (has_wild && !find_host) { | 1098 | if (has_wild && !find_host) { |
1099 | logit("%s:%ld: ignoring host name " | 1099 | logit("%s:%lu: ignoring host name " |
1100 | "with wildcard: %.64s", l->path, | 1100 | "with wildcard: %.64s", l->path, |
1101 | l->linenum, l->hosts); | 1101 | l->linenum, l->hosts); |
1102 | } | 1102 | } |
@@ -1118,7 +1118,7 @@ known_hosts_hash(struct hostkey_foreach_line *l, void *_ctx) | |||
1118 | case HKF_STATUS_INVALID: | 1118 | case HKF_STATUS_INVALID: |
1119 | /* Retain invalid lines, but mark file as invalid. */ | 1119 | /* Retain invalid lines, but mark file as invalid. */ |
1120 | ctx->invalid = 1; | 1120 | ctx->invalid = 1; |
1121 | logit("%s:%ld: invalid line", l->path, l->linenum); | 1121 | logit("%s:%lu: invalid line", l->path, l->linenum); |
1122 | /* FALLTHROUGH */ | 1122 | /* FALLTHROUGH */ |
1123 | default: | 1123 | default: |
1124 | fprintf(ctx->out, "%s\n", l->line); | 1124 | fprintf(ctx->out, "%s\n", l->line); |
@@ -1152,14 +1152,14 @@ known_hosts_find_delete(struct hostkey_foreach_line *l, void *_ctx) | |||
1152 | */ | 1152 | */ |
1153 | ctx->found_key = 1; | 1153 | ctx->found_key = 1; |
1154 | if (!quiet) | 1154 | if (!quiet) |
1155 | printf("# Host %s found: line %ld\n", | 1155 | printf("# Host %s found: line %lu\n", |
1156 | ctx->host, l->linenum); | 1156 | ctx->host, l->linenum); |
1157 | } | 1157 | } |
1158 | return 0; | 1158 | return 0; |
1159 | } else if (find_host) { | 1159 | } else if (find_host) { |
1160 | ctx->found_key = 1; | 1160 | ctx->found_key = 1; |
1161 | if (!quiet) { | 1161 | if (!quiet) { |
1162 | printf("# Host %s found: line %ld %s\n", | 1162 | printf("# Host %s found: line %lu %s\n", |
1163 | ctx->host, | 1163 | ctx->host, |
1164 | l->linenum, l->marker == MRK_CA ? "CA" : | 1164 | l->linenum, l->marker == MRK_CA ? "CA" : |
1165 | (l->marker == MRK_REVOKE ? "REVOKED" : "")); | 1165 | (l->marker == MRK_REVOKE ? "REVOKED" : "")); |
@@ -1179,7 +1179,7 @@ known_hosts_find_delete(struct hostkey_foreach_line *l, void *_ctx) | |||
1179 | /* Retain non-matching hosts when deleting */ | 1179 | /* Retain non-matching hosts when deleting */ |
1180 | if (l->status == HKF_STATUS_INVALID) { | 1180 | if (l->status == HKF_STATUS_INVALID) { |
1181 | ctx->invalid = 1; | 1181 | ctx->invalid = 1; |
1182 | logit("%s:%ld: invalid line", l->path, l->linenum); | 1182 | logit("%s:%lu: invalid line", l->path, l->linenum); |
1183 | } | 1183 | } |
1184 | fprintf(ctx->out, "%s\n", l->line); | 1184 | fprintf(ctx->out, "%s\n", l->line); |
1185 | } | 1185 | } |