summaryrefslogtreecommitdiff
path: root/apps
diff options
context:
space:
mode:
authorRussell Bryant <russell@russellbryant.com>2005-05-25 10:57:15 +0000
committerRussell Bryant <russell@russellbryant.com>2005-05-25 10:57:15 +0000
commit9644f1dcfe31c89fb5d1003e9932f93ca28bf6d8 (patch)
tree9a917a19f9faf4d2766126637a1244fa001c054a /apps
parent5d5c4c97c7a699bb8802ba8c53955485de23e36a (diff)
various code cleanups (bug #4353)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@5764 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'apps')
-rwxr-xr-xapps/app_controlplayback.c15
-rwxr-xr-xapps/app_dictate.c2
-rwxr-xr-xapps/app_flash.c6
3 files changed, 9 insertions, 14 deletions
diff --git a/apps/app_controlplayback.c b/apps/app_controlplayback.c
index bf56dcaa2..02a1cd384 100755
--- a/apps/app_controlplayback.c
+++ b/apps/app_controlplayback.c
@@ -65,24 +65,19 @@ static int controlplayback_exec(struct ast_channel *chan, void *data)
file = tmp;
if ((skip=strchr(tmp,'|'))) {
- *skip = '\0';
- *skip++;
+ *skip++ = '\0';
fwd=strchr(skip,'|');
if (fwd) {
- *fwd = '\0';
- *fwd++;
+ *fwd++ = '\0';
rev = strchr(fwd,'|');
if (rev) {
- *rev = '\0';
- *rev++;
+ *rev++ = '\0';
stop = strchr(rev,'|');
if (stop) {
- *stop = '\0';
- *stop++;
+ *stop++ = '\0';
pause = strchr(stop,'|');
if (pause) {
- *pause = '\0';
- *pause++;
+ *pause++ = '\0';
}
}
}
diff --git a/apps/app_dictate.c b/apps/app_dictate.c
index b88fbf2c3..97efef19c 100755
--- a/apps/app_dictate.c
+++ b/apps/app_dictate.c
@@ -16,7 +16,7 @@
#include <stdlib.h>
#include <unistd.h>
#include <string.h>
-
+#include <sys/stat.h> /* for mkdir */
#include "asterisk/file.h"
#include "asterisk/logger.h"
#include "asterisk/channel.h"
diff --git a/apps/app_flash.c b/apps/app_flash.c
index 9c8e8dbec..7514ef0bf 100755
--- a/apps/app_flash.c
+++ b/apps/app_flash.c
@@ -11,6 +11,9 @@
* the GNU General Public License
*/
+#include <string.h>
+#include <errno.h>
+#include <stdlib.h>
#include "asterisk/lock.h"
#include "asterisk/file.h"
#include "asterisk/logger.h"
@@ -26,9 +29,6 @@
#else
#include <zaptel.h>
#endif /* __linux__ */
-#include <string.h>
-#include <errno.h>
-#include <stdlib.h>
static char *tdesc = "Flash zap trunk application";