[asterisk-dev] [svn-commits] mmichelson: trunk r71914 - /trunk/apps/app_record.c
Russell Bryant
russell at digium.com
Wed Jun 27 07:57:32 CDT 2007
SVN commits to the Digium repositories wrote:
> + /* Create the directory if it does not exist. */
> + dir = ast_strdupa(tmp);
> + if ((file = strrchr(dir, '/')))
> + *file++ = '\0';
The previous two lines can be simplified by using:
dir = strsep(&dir, "/");
Then, you don't need the file var at all.
> + ast_mkdir (dir, 0777);
> +
There is a stray space in there. :)
--
Russell Bryant
Software Engineer
Digium, Inc.
More information about the asterisk-dev
mailing list