summaryrefslogtreecommitdiff
path: root/gnuradio-core
diff options
context:
space:
mode:
Diffstat (limited to 'gnuradio-core')
-rw-r--r--gnuradio-core/src/lib/runtime/gr_single_threaded_scheduler.cc6
1 files changed, 3 insertions, 3 deletions
diff --git a/gnuradio-core/src/lib/runtime/gr_single_threaded_scheduler.cc b/gnuradio-core/src/lib/runtime/gr_single_threaded_scheduler.cc
index 7f1b40641..ae04e4a65 100644
--- a/gnuradio-core/src/lib/runtime/gr_single_threaded_scheduler.cc
+++ b/gnuradio-core/src/lib/runtime/gr_single_threaded_scheduler.cc
@@ -29,6 +29,7 @@
#include <gr_block_detail.h>
#include <gr_buffer.h>
#include <boost/thread.hpp>
+#include <boost/format.hpp>
#include <iostream>
#include <limits>
#include <assert.h>
@@ -57,9 +58,8 @@ gr_single_threaded_scheduler::gr_single_threaded_scheduler (
: d_blocks (blocks), d_enabled (true), d_log(0)
{
if (ENABLE_LOGGING){
- char name[100];
- snprintf(name, sizeof(name), "sst-%d.log", which_scheduler++);
- d_log = new std::ofstream(name);
+ std::string name = str(boost::format("sst-%d.log") % which_scheduler++);
+ d_log = new std::ofstream(name.c_str());
*d_log << "gr_single_threaded_scheduler: "
<< d_blocks.size ()
<< " blocks\n";