]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
2152. [cleanup] Use sizeof(buf) instead of fixed number in
authorMark Andrews <marka@isc.org>
Tue, 27 Feb 2007 00:58:08 +0000 (00:58 +0000)
committerMark Andrews <marka@isc.org>
Tue, 27 Feb 2007 00:58:08 +0000 (00:58 +0000)
                        dighost.c:get_trusted_key(). [RT #16678]

CHANGES
bin/dig/dighost.c

diff --git a/CHANGES b/CHANGES
index 9e06b3264f0d0bab066fda188649390e968af1de..12d707410644ed00ea07ce5a84da0f46d3d27604 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -1,3 +1,6 @@
+2152.  [cleanup]       Use sizeof(buf) instead of fixed number in
+                       dighost.c:get_trusted_key(). [RT #16678]
+
 2151.  [bug]           Missing newline in usage message for journalprint.
                        [RT #16679]
 
index b2139495cfda38096b121ecb79a6b369aa5d1e96..5219f5ec0ff4d5304253ecf964d04f13071e4a9e 100644 (file)
@@ -15,7 +15,7 @@
  * PERFORMANCE OF THIS SOFTWARE.
  */
 
-/* $Id: dighost.c,v 1.300 2007/02/26 00:27:09 marka Exp $ */
+/* $Id: dighost.c,v 1.301 2007/02/27 00:58:08 marka Exp $ */
 
 /*! \file
  *  \note
@@ -3892,7 +3892,7 @@ get_trusted_key(isc_mem_t *mctx)
                       filename);
                return (ISC_R_FAILURE);
        }
-       while (fgets(buf, 1500, fp) != NULL) {
+       while (fgets(buf, sizeof(buf), fp) != NULL) {
                result = opentmpkey(mctx,"tmp_file", &filetemp, &fptemp);
                if (result != ISC_R_SUCCESS) {
                        fclose(fp);