5 Commits

Author SHA1 Message Date
A. Taber
a0118a0dd0 Merge pull request #381 from cooolgamer/assets-fix
add missing assets
2026-10-13 14:47:58 -04:00
cooolgamer
b930df77d6 add missing assets
fixes the app crash at boot
2026-10-12 22:04:36 +02:00
A. Taber
2ea21c45ea Merge pull request #379 from ThemezerNX/codex/fix-bcstm-sound-modes
Fix BCSTM previews in Stereo and Mono
2026-10-09 11:28:11 -04:00
Migush
5f94a6fc63 Fix BCSTM previews in Stereo and Mono 2026-10-09 15:41:35 +02:00
Théo B.
4d223a1754 make the curl case of http_get not explode when no Content-Disposition (#374)
* make the curl case of http_get not explode when no Content-Disposition

* style
2026-08-18 10:14:28 +01:00
6 changed files with 23 additions and 20 deletions

2
.gitignore vendored
View File

@@ -58,7 +58,7 @@ dkms.conf
# Build files
build/
out/
romfs/
romfs/gfx/
# Sublime stuff
.clang_complete

BIN
romfs/anemone_set.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 14 KiB

BIN
romfs/hb_set.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.1 KiB

BIN
romfs/tp_set.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.1 KiB

View File

@@ -247,7 +247,7 @@ int start_play(audio_s *audio) {
ndspChnWaveBufClear(audio->channel[i]);
static float mix[16];
ndspChnSetFormat(audio->channel[i], NDSP_FORMAT_ADPCM | NDSP_3D_SURROUND_PREPROCESSED);
ndspChnSetFormat(audio->channel[i], NDSP_FORMAT_ADPCM);
ndspChnSetRate(audio->channel[i], audio->sample_rate);
if (audio->channel_count == 1)

View File

@@ -1009,12 +1009,12 @@ static size_t curl_parse_header(char *buffer, size_t size, size_t nitems, void *
}
}
if (!strncmp(buffer, "Content-Type: ", 14))
if (!strncasecmp(buffer, "Content-Type: ", 14))
{
header->mime_type = malloc(strlen(buffer) - 13);
strncpy(header->mime_type, buffer + 14, strlen(buffer) - 14);
header->mime_type[strlen(buffer) - 14] = '\0';
} else if (!strncmp(buffer, "Content-Disposition: ", 21))
} else if (!strncasecmp(buffer, "Content-Disposition: ", 21))
{
header->filename = malloc(strlen(buffer) - 20);
memcpy(header->filename, buffer + 21, strlen(buffer) - 21);
@@ -1098,6 +1098,8 @@ static int64_t curl_http_get(const char * url, char ** out_filename, char ** buf
}
DEBUG("Content-Disposition: %s\n", header.filename);
if (out_filename)
{
if (header.filename)
{
char *filename = strstr(header.filename, "filename=");
@@ -1122,6 +1124,7 @@ static int64_t curl_http_get(const char * url, char ** out_filename, char ** buf
} else {
*out_filename = NULL;
}
}
*buf = data.result_buf;
*size = data.result_written;