Skip to content

Instantly share code, notes, and snippets.

@inactive123
inactive123 / retroarch_tunnel_config.ini
Created November 28, 2021 18:24
retroarch_tunnel_config.ini
[Server]
Port = 5555
Timeout = 120
[Session]
Max = 128
Clients = 8
[Log]
Path = tunnel.log
@inactive123
inactive123 / retroarch_tunnel_server.py
Created November 28, 2021 18:19
retroarch_tunnel_server.py
# RetroArch - A frontend for libretro.
# Copyright (C) 2021 - The RetroArch team
#
# RetroArch is free software: you can redistribute it and/or modify it under the terms
# of the GNU General Public License as published by the Free Software Found-
# ation, either version 3 of the License, or (at your option) any later version.
#
# RetroArch is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
# without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
# PURPOSE. See the GNU General Public License for more details.
@inactive123
inactive123 / gist:1613a96ac82d28fbb54aaf26768b9741
Created November 21, 2021 07:31
retroarch_tunnel_server.py
# RetroArch - A frontend for libretro.
# Copyright (C) 2021 - The RetroArch team
#
# RetroArch is free software: you can redistribute it and/or modify it under the terms
# of the GNU General Public License as published by the Free Software Found-
# ation, either version 3 of the License, or (at your option) any later version.
#
# RetroArch is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
# without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
# PURPOSE. See the GNU General Public License for more details.
/* BEGIN debugbreak.c */
#ifndef _WIN32_WINNT
#define _WIN32_WINNT 0x0501
#endif
#if _WIN32_WINNT < 0x0501
#error Must target Windows NT 5.0.1 or later for DebugBreakProcess
#endif
/* BEGIN debugbreak.c */
#ifndef _WIN32_WINNT
#define _WIN32_WINNT 0x0501
#endif
#if _WIN32_WINNT < 0x0501
#error Must target Windows NT 5.0.1 or later for DebugBreakProcess
#endif
diff --git a/audio/audio_driver.c b/audio/audio_driver.c
index bc2231c76e..ab0f0bd73c 100644
--- a/audio/audio_driver.c
+++ b/audio/audio_driver.c
@@ -739,6 +739,8 @@ size_t audio_driver_sample_batch(const int16_t *data, size_t frames)
**/
void audio_driver_sample_rewind(int16_t left, int16_t right)
{
+ if (audio_driver_rewind_ptr == 0)
+ return;
#define _WIN32_WINNT 0x0600
#include <windows.h>
#include <dwmapi.h>
#include <stdio.h>
#include <inttypes.h>
uint64_t qpc_freq;
static void print_ratio(const char *name, UNSIGNED_RATIO val)
{
#define _WIN32_WINNT 0x0600
#include <windows.h>
#include <dwmapi.h>
#include <stdio.h>
#include <inttypes.h>
uint64_t qpc_freq;
static void print_ratio(const char *name, UNSIGNED_RATIO val)
{
#0 0x00007fb1ba641a10 in raise () from /usr/lib/libc.so.6
[Current thread is 1 (Thread 0x7fb1c2c3b180 (LWP 21724))]
(gdb) bt
#0 0x00007fb1ba641a10 in raise () from /usr/lib/libc.so.6
#1 0x00007fb1ba64313a in abort () from /usr/lib/libc.so.6
#2 0x00007fb1bef894ed in __gnu_cxx::__verbose_terminate_handler ()
at /build/gcc/src/gcc/libstdc++-v3/libsupc++/vterminate.cc:95
#3 0x00007fb1bef872a6 in __cxxabiv1::__terminate (handler=<optimized out>)
at /build/gcc/src/gcc/libstdc++-v3/libsupc++/eh_terminate.cc:47
#4 0x00007fb1bef872f1 in std::terminate () at /build/gcc/src/gcc/libstdc++-v3/libsupc++/eh_terminate.cc:57
recSh4:Dynarec Cache clear at AC183BC2
SPI : unknown ? [0x70]
SPI : unknown ? [0x71]
Error in core/hw/holly/sb_mem.cpp:WriteBios:70 -> Write to [Boot ROM] is not possible, addr=0,data=0,size=4
Error in core/hw/holly/sb_mem.cpp:WriteBios:70 -> Write to [Boot ROM] is not possible, addr=4,data=0,size=4
Error in core/hw/holly/sb_mem.cpp:WriteBios:70 -> Write to [Boot ROM] is not possible, addr=8,data=0,size=4
Error in core/hw/holly/sb_mem.cpp:WriteBios:70 -> Write to [Boot ROM] is not possible, addr=c,data=0,size=4
Error in core/hw/holly/sb_mem.cpp:WriteBios:70 -> Write to [Boot ROM] is not possible, addr=10,data=0,size=4
Error in core/hw/holly/sb_mem.cpp:WriteBios:70 -> Write to [Boot ROM] is not possible, addr=14,data=0,size=4
Error in core/hw/holly/sb_mem.cpp:WriteBios:70 -> Write to [Boot ROM] is not possible, addr=18,data=0,size=4