Closed Joshix-1 closed 2 years ago
The replace function also uses recursion. On my system the pr worked. Without the recursion I don't think the problem is fixed, but I need to try it.
On both my PCs it works, I will try it also on a vm, just to be sure
The problem is that it doesn't replace multiple instances of the word. In my GPU info there is two times "Radeon" it only replaces the first one.
How did you get the segfault?
According to gdb it calls replace_ignorecase
endlessly
What's the string? The following check should prevent the infinite recursion, like the similar check in the replace function should.
if (!(ch = strcasestr(original, search)))
return;