Hi,
I'm a senior C++ developer with more than 15 years of experience, mostly as team leader. As such, one of my main tasks is to review and fix code from other people.
You didn't specify the compiler version, etc. For this kind of problem it usually doesn't really matter if you are using Linux or Windows, but newer compilers offer you ways to avoid segmentation faults. I can send you two version of the fixed code, one with raw pointers and another using smart pointers, so you can decide which one to use.
You state you are an inexperienced programmer; my advice to you is to learn and use the features of C++11, you will not have any performance degradation using STL containers and smart pointers.
Please let me know if you have any doubts about this proposal. It is the kind of work to be done in about an hour, as you say, so I can send you the fixed code in the same day you accept this bid.
Best regards,
Gustavo Schirmer dos Santos, PMP