Merged revisions 77869 via svnmerge from

https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r77869 | file | 2007-08-01 14:56:59 -0300 (Wed, 01 Aug 2007) | 2 lines

Add some fixes for building on Solaris.

........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77870 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
Joshua Colp
2007-08-01 18:01:33 +00:00
parent 28fec17d59
commit d9aee5e353
5 changed files with 20 additions and 14 deletions

View File

@@ -125,7 +125,7 @@ static char txqcheck (char *dir, char *queue, char subaddress, char *channel, ch
ql = p - queue;
subaddress = p[1];
}
snprintf (temp, sizeof(temp), "sms/.smsq-%d", getpid ());
snprintf (temp, sizeof(temp), "sms/.smsq-%d", (int)getpid ());
f = fopen (temp, "w");
if (!f)
{
@@ -196,7 +196,7 @@ static void rxqcheck (char *dir, char *queue, char *process)
DIR *d;
int ql = strlen (queue);
struct dirent *fn;
snprintf(temp, sizeof(temp), "sms/.smsq-%d", getpid ());
snprintf(temp, sizeof(temp), "sms/.smsq-%d", (int)getpid ());
snprintf(dirname, sizeof(dirname), "sms/%s", dir);
d = opendir (dirname);
if (!d)
@@ -673,10 +673,10 @@ main (int argc, const char *argv[])
queuename[100],
*dir = (mo ? rx ? "sms/morx" : "sms/motx" : rx ? "sms/mtrx" : "sms/mttx");
FILE *f;
snprintf (temp, sizeof(temp), "sms/.smsq-%d", getpid ());
snprintf (temp, sizeof(temp), "sms/.smsq-%d", (int)getpid ());
mkdir ("sms", 0777); /* ensure directory exists */
mkdir (dir, 0777); /* ensure directory exists */
snprintf (queuename, sizeof(queuename), "%s/%s.%ld-%d", dir, *queue ? queue : "0", (long)time (0), getpid ());
snprintf (queuename, sizeof(queuename), "%s/%s.%ld-%d", dir, *queue ? queue : "0", (long)time (0), (int)getpid ());
f = fopen (temp, "w");
if (!f)
{