diff options
author | pfg <pfg@FreeBSD.org> | 2014-08-28 18:11:05 +0000 |
---|---|---|
committer | pfg <pfg@FreeBSD.org> | 2014-08-28 18:11:05 +0000 |
commit | 564b330f17f47a63364f8c45c76c24493a627165 (patch) | |
tree | 3d904b740bbafd0a43dee99599d230f2e5384ec4 /usr.bin | |
parent | d3edf358e534ec56f98b2f0a586698b9621b6fa7 (diff) | |
download | FreeBSD-src-564b330f17f47a63364f8c45c76c24493a627165.zip FreeBSD-src-564b330f17f47a63364f8c45c76c24493a627165.tar.gz |
MFC r270256:
Always check the limits of array index variables before using them.
Obtained from: DragonFlyBSD
Diffstat (limited to 'usr.bin')
-rw-r--r-- | usr.bin/mail/edit.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/usr.bin/mail/edit.c b/usr.bin/mail/edit.c index ad8aa53..f9e974d 100644 --- a/usr.bin/mail/edit.c +++ b/usr.bin/mail/edit.c @@ -81,7 +81,7 @@ edit1(int *msgvec, int type) /* * Deal with each message to be edited . . . */ - for (i = 0; msgvec[i] && i < msgCount; i++) { + for (i = 0; i < msgCount && msgvec[i]; i++) { sig_t sigint; if (i > 0) { |