From RCE to DOS
...the flaws found in curl would not have existed had it been written in a more memory-safe language...
Instead, the logic errors would probably translate in denial of service problems.
A memory error is, of course, serious and problematic, but the cause is due to a logic error in the code. Like, I expected 3 but got 4. Rewriting the code in another language may very well fence off the class of memory errors. However, the logic error now translates into an exceptional state that needs to be handled. And how do you handle an error you didn't account for? Well, you can be lucky and somehow terminate or you can end in an endless loop. And that is a clear opening to a denial of service. One can argue that DOS is not as bad as RCE, but when it overflows/deletes your data stores, then you would not be happy either.