This is why I set up a Namespace that has ONE Char Buffer of 1024bytes - so I have a nice sized buffer and I can use it everywhere.
jfc_common.h - stripped for thread topic
#pragma once
//============================================================================
//============================================================================
namespace JFC{
//============================================================================
extern char CHAR1K[1024];
};
//============================================================================
jfc_common.cpp - also stripped to just pertain to this thread
#include "jfc_common.h"
//============================================================================
// begin JFC_COMMON
//============================================================================
namespace JFC{
char CHAR1K[1024];
};
//============================================================================
Then I include jgc_common.h everywhere and I can do:
sprintf(JFC::CHAR1K, "Somethere %i %i",10,20);dbPrint(JFC::CHAR1K);