From a00a922119898c70337a0a6d1233ce274ea91e27 Mon Sep 17 00:00:00 2001 From: Tobias Doerffel Date: Mon, 3 Dec 2012 00:05:36 +0100 Subject: [PATCH] RemotePlugin: smaller buffers for printing numbers --- include/RemotePlugin.h | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/include/RemotePlugin.h b/include/RemotePlugin.h index 5e03a724a..58a7d0465 100644 --- a/include/RemotePlugin.h +++ b/include/RemotePlugin.h @@ -546,8 +546,7 @@ public: message & addInt( int _i ) { - char buf[128]; - buf[0] = 0; + char buf[32]; sprintf( buf, "%d", _i ); data.push_back( std::string( buf ) ); return *this; @@ -555,8 +554,7 @@ public: message & addFloat( float _f ) { - char buf[128]; - buf[0] = 0; + char buf[32]; sprintf( buf, "%f", _f ); data.push_back( std::string( buf ) ); return *this;