Re: Crashes with builds from today and yesterday [typo fix]
- From: Roland Illig <roland illig gmx de>
- To: MC Devel <mc-devel gnome org>
- Subject: Re: Crashes with builds from today and yesterday [typo fix]
- Date: Wed, 22 Sep 2004 14:10:27 +0200
Roland Illig wrote:
----
g_strdup: If you use g_strdup to create a local copy of a string, use
the following pattern to keep the reference.
char * const pathref = g_strdup(argument);
/* ... */
g_free (pathref);
- The "const" will make the pointer unmodifiable (local_copy++
+ The "const" will make the pointer unmodifiable (pathref++
is not possible), but you can still modify the string contents.
----
Roland
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]