From 466e99688eb37179ef13dfcee6c1f29b662f40a0 Mon Sep 17 00:00:00 2001 From: Miles Bader Date: Mon, 23 Sep 1996 17:16:45 +0000 Subject: (diskfs_S_io_server_version): Use snprintf instead of sprintf. : New include. --- libdiskfs/io-version.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'libdiskfs') diff --git a/libdiskfs/io-version.c b/libdiskfs/io-version.c index 0dba8046..b19dd0d1 100644 --- a/libdiskfs/io-version.c +++ b/libdiskfs/io-version.c @@ -19,6 +19,8 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */ /* Written by Michael I. Bushnell. */ +#include + #include "priv.h" #include "io_S.h" @@ -31,8 +33,8 @@ diskfs_S_io_server_version (struct protid *cred, { if (cred) { - sprintf (server_name, "%s %s", - diskfs_server_name, diskfs_server_version); + snprintf (server_name, sizeof (string_t), "%s %s", + diskfs_server_name, diskfs_server_version); return 0; } else -- cgit v1.2.3