diff options
Diffstat (limited to 'g10/openfile.c')
-rw-r--r-- | g10/openfile.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/g10/openfile.c b/g10/openfile.c index 79c99785a..f207dd2bb 100644 --- a/g10/openfile.c +++ b/g10/openfile.c @@ -267,7 +267,7 @@ open_sigfile( const char *iname ) || !strcmp(iname + len - 4, ".asc")) ) { char *buf; buf = m_strdup(iname); - buf[len-4] = 0 ; + buf[len-(buf[len-1]=='n'?5:4)] = 0 ; a = iobuf_open( buf ); if( a && opt.verbose ) log_info(_("assuming signed data in `%s'\n"), buf ); |