Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/ddb ddb(4): Use db_num_to_strbuf in db_symstr.



details:   https://anonhg.NetBSD.org/src/rev/d3cd2a2863b5
branches:  trunk
changeset: 369769:d3cd2a2863b5
user:      riastradh <riastradh%NetBSD.org@localhost>
date:      Tue Aug 30 22:37:36 2022 +0000

description:
ddb(4): Use db_num_to_strbuf in db_symstr.

Simplifies it and will make safer to use.

diffstat:

 sys/ddb/db_sym.c |  6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diffs (27 lines):

diff -r c04778693849 -r d3cd2a2863b5 sys/ddb/db_sym.c
--- a/sys/ddb/db_sym.c  Tue Aug 30 22:37:03 2022 +0000
+++ b/sys/ddb/db_sym.c  Tue Aug 30 22:37:36 2022 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: db_sym.c,v 1.69 2021/12/13 03:17:50 kre Exp $  */
+/*     $NetBSD: db_sym.c,v 1.70 2022/08/30 22:37:36 riastradh Exp $    */
 
 /*
  * Mach Operating System
@@ -27,7 +27,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: db_sym.c,v 1.69 2021/12/13 03:17:50 kre Exp $");
+__KERNEL_RCSID(0, "$NetBSD: db_sym.c,v 1.70 2022/08/30 22:37:36 riastradh Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_ddbparam.h"
@@ -372,7 +372,7 @@
                }
        }
 out:
-       strlcpy(buf, db_num_to_str(off), buflen);
+       db_num_to_strbuf(off, buf, buflen);
 #endif
 }
 



Home | Main Index | Thread Index | Old Index