Skip to content

Commit c5ad945

Browse files
authored
Fix IL2PTX config parsing (#483)
We were checking `*t` for end of string instead of `*c`, but `t` never changes, so we would run off of the end of the buffer and output a very large number of config errors before eventually crashing.
1 parent fed79a7 commit c5ad945

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/config.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -2380,7 +2380,7 @@ void config_init (char *fname, struct audio_s *p_audio_config,
23802380
p_audio_config->achan[channel].il2p_invert_polarity = 0;
23812381

23822382
while ((t = split(NULL,0)) != NULL) {
2383-
for (char *c = t; *t != '\0'; c++) {
2383+
for (char *c = t; *c != '\0'; c++) {
23842384
switch (*c) {
23852385
case '+':
23862386
p_audio_config->achan[channel].il2p_invert_polarity = 0;

0 commit comments

Comments
 (0)