2017-11-24 15:14:10 +01:00
|
|
|
/*
|
2019-08-03 19:43:48 +02:00
|
|
|
* This software is licensed under the terms of the MIT License.
|
2017-11-24 15:14:10 +01:00
|
|
|
* See COPYING for further information.
|
|
|
|
* ---
|
2024-05-16 23:30:41 +02:00
|
|
|
* Copyright (c) 2011-2024, Lukas Weber <laochailan@web.de>.
|
|
|
|
* Copyright (c) 2012-2024, Andrei Alexeyev <akari@taisei-project.org>.
|
2017-11-24 15:14:10 +01:00
|
|
|
*/
|
|
|
|
|
2018-05-15 02:27:25 +02:00
|
|
|
#include "crap.h"
|
2018-10-23 09:51:56 +02:00
|
|
|
#include "assert.h"
|
2017-11-24 15:14:10 +01:00
|
|
|
|
2019-01-09 04:25:10 +01:00
|
|
|
#include <SDL_thread.h>
|
2017-11-24 15:14:10 +01:00
|
|
|
|
2018-10-23 09:51:56 +02:00
|
|
|
static_assert(sizeof(void*) == sizeof(void (*)(void)), "Can't store function pointers in void* :(");
|
|
|
|
|
|
|
|
void inherit_missing_pointers(uint num, void *dest[num], void *const base[num]) {
|
|
|
|
for(uint i = 0; i < num; ++i) {
|
|
|
|
if(dest[i] == NULL) {
|
|
|
|
dest[i] = base[i];
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|