From 01ea0040308b79a9f7637813f3ab39444f30f066 Mon Sep 17 00:00:00 2001 From: Glenn Maynard Date: Mon, 29 Mar 2004 20:47:29 +0000 Subject: [PATCH] default string in case confstr is broken --- stepmania/src/arch/ArchHooks/ArchHooks_Unix.cpp | 2 +- stepmania/src/archutils/Unix/LinuxThreadHelpers.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/stepmania/src/arch/ArchHooks/ArchHooks_Unix.cpp b/stepmania/src/arch/ArchHooks/ArchHooks_Unix.cpp index c57a531104..63ecedc785 100644 --- a/stepmania/src/arch/ArchHooks/ArchHooks_Unix.cpp +++ b/stepmania/src/arch/ArchHooks/ArchHooks_Unix.cpp @@ -80,7 +80,7 @@ ArchHooks_Unix::ArchHooks_Unix() static CString LibcVersion() { - char buf[1024]; + char buf[1024] = "(error)"; int ret = confstr( _CS_GNU_LIBC_VERSION, buf, sizeof(buf) ); if( ret == -1 ) return "(unknown)"; diff --git a/stepmania/src/archutils/Unix/LinuxThreadHelpers.cpp b/stepmania/src/archutils/Unix/LinuxThreadHelpers.cpp index a90fd2e04b..5a88f48234 100644 --- a/stepmania/src/archutils/Unix/LinuxThreadHelpers.cpp +++ b/stepmania/src/archutils/Unix/LinuxThreadHelpers.cpp @@ -101,7 +101,7 @@ static int PtraceDetach( int ThreadID ) CString ThreadsVersion() { - char buf[1024]; + char buf[1024] = "(error)"; int ret = confstr( _CS_GNU_LIBPTHREAD_VERSION, buf, sizeof(buf) ); if( ret == -1 ) return "(unknown)";