|
@@ -1205,10 +1205,14 @@ AdvancedOutput::AdvancedOutput(OBSBasic *main_) : BasicOutputHandler(main_)
|
|
|
bool useReplayBuffer =
|
|
|
config_get_bool(main->Config(), "AdvOut", "RecRB");
|
|
|
if (useReplayBuffer) {
|
|
|
+ OBSDataAutoRelease hotkey;
|
|
|
const char *str = config_get_string(
|
|
|
main->Config(), "Hotkeys", "ReplayBuffer");
|
|
|
- OBSDataAutoRelease hotkey =
|
|
|
- obs_data_create_from_json(str);
|
|
|
+ if (str)
|
|
|
+ hotkey = obs_data_create_from_json(str);
|
|
|
+ else
|
|
|
+ hotkey = nullptr;
|
|
|
+
|
|
|
replayBuffer = obs_output_create("replay_buffer",
|
|
|
Str("ReplayBuffer"),
|
|
|
nullptr, hotkey);
|