How to perform a deep copy of a char *?
<p>I'm a little confused on how to perform a deep copy a of a char *. This is what I have:</p>

<pre><code>Appointment(Appointment&amp; a)
{
  subject = new char;
  *subject = *(a.subject);
}

Appointment(Appointment&amp; b)
{
  location = new char;
  *location = *(b.location);
}

char *subject;
char *location;
</code></pre>

<p>I'm trying to perform a deep copy of the char pointers subject and location. Will this work? If not, any advice on how to go about doing this?</p>
