mirror of
https://github.com/Atmosphere-NX/Atmosphere
synced 2024-12-23 04:41:12 +00:00
Fusee: Actually write SD path in stratosphere_merge_inis
This commit is contained in:
parent
7ddf5a922c
commit
375a0b3fa8
2 changed files with 5 additions and 0 deletions
|
@ -20,6 +20,7 @@ struct va_format {
|
||||||
unsigned long long simple_strtoull(const char *cp, char **endp, unsigned int base);
|
unsigned long long simple_strtoull(const char *cp, char **endp, unsigned int base);
|
||||||
|
|
||||||
int vsnprintf(char *buf, size_t size, const char *fmt, va_list args);
|
int vsnprintf(char *buf, size_t size, const char *fmt, va_list args);
|
||||||
|
int snprintf(char *buf, size_t size, const char *fmt, ...);
|
||||||
int sscanf(const char *buf, const char *fmt, ...);
|
int sscanf(const char *buf, const char *fmt, ...);
|
||||||
|
|
||||||
#endif /* VSPRINTF_H */
|
#endif /* VSPRINTF_H */
|
||||||
|
|
|
@ -3,6 +3,7 @@
|
||||||
#include "stratosphere.h"
|
#include "stratosphere.h"
|
||||||
#include "sd_utils.h"
|
#include "sd_utils.h"
|
||||||
#include "lib/printk.h"
|
#include "lib/printk.h"
|
||||||
|
#include "lib/vsprintf.h"
|
||||||
|
|
||||||
unsigned char g_stratosphere_ini1[PACKAGE2_SIZE_MAX];
|
unsigned char g_stratosphere_ini1[PACKAGE2_SIZE_MAX];
|
||||||
static bool g_initialized_stratosphere_ini1 = false;
|
static bool g_initialized_stratosphere_ini1 = false;
|
||||||
|
@ -69,6 +70,9 @@ void stratosphere_merge_inis(void *dst, ini1_header_t **inis, unsigned int num_i
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* TODO: What folder should these be read out of? */
|
||||||
|
snprintf(sd_path, sizeof(sd_path), "atmosph\xe8re/titles/%016llx/%016llx.kip", current_kip->title_id, current_kip->title_id);
|
||||||
|
|
||||||
/* Try to load an override KIP from SD, if possible. */
|
/* Try to load an override KIP from SD, if possible. */
|
||||||
if (read_sd_file(current_dst_kip, remaining_size, sd_path)) {
|
if (read_sd_file(current_dst_kip, remaining_size, sd_path)) {
|
||||||
kip1_header_t *sd_kip = (kip1_header_t *)(current_dst_kip);
|
kip1_header_t *sd_kip = (kip1_header_t *)(current_dst_kip);
|
||||||
|
|
Loading…
Reference in a new issue