I am reading a pathname from the registry and storing it in a char*. For example "C:\Winnt\file.txt" is stored in a char*. Now, when I want to open up this file, the "\"'s are escape sequences so the stream that I am trying to open doesn't exist (C:Winntfile.txt). So my question is how do I add the escape sequence "\" in front of the "\"'s already in the char*? Is there a way when reading from the registry to automatically add these extra slashes? If not, how can I search for the single slashes in the string?