Fixes and a comment
This commit is contained in:
parent
db2f079266
commit
00ee155176
1 changed files with 5 additions and 0 deletions
|
@ -1,5 +1,9 @@
|
||||||
#include "../Platform.h"
|
#include "../Platform.h"
|
||||||
|
|
||||||
|
#include <stddef.h>
|
||||||
|
#include <stdio.h>
|
||||||
|
#include <string.h>
|
||||||
|
|
||||||
#include "SDL.h"
|
#include "SDL.h"
|
||||||
|
|
||||||
#include "../Rendering.h"
|
#include "../Rendering.h"
|
||||||
|
@ -57,6 +61,7 @@ void PlatformBackend_PostWindowCreation(void)
|
||||||
BOOL PlatformBackend_GetBasePath(char *string_buffer)
|
BOOL PlatformBackend_GetBasePath(char *string_buffer)
|
||||||
{
|
{
|
||||||
char *base_path = SDL_GetBasePath();
|
char *base_path = SDL_GetBasePath();
|
||||||
|
// Trim the trailing '/'
|
||||||
size_t base_path_length = strlen(base_path);
|
size_t base_path_length = strlen(base_path);
|
||||||
base_path[base_path_length - 1] = '\0';
|
base_path[base_path_length - 1] = '\0';
|
||||||
strcpy(string_buffer, base_path);
|
strcpy(string_buffer, base_path);
|
||||||
|
|
Loading…
Add table
Reference in a new issue