[launchd-changes] [23388] trunk/launchd/src
source_changes at macosforge.org
source_changes at macosforge.org
Fri Sep 14 13:25:43 PDT 2007
Revision: 23388
http://trac.macosforge.org/projects/launchd/changeset/23388
Author: zarzycki at apple.com
Date: 2007-09-14 13:25:43 -0700 (Fri, 14 Sep 2007)
Log Message:
-----------
We need to finish building launchd with -Wshorten-64-to-32 someday...
Modified Paths:
--------------
trunk/launchd/src/launchctl.c
trunk/launchd/src/launchd_core_logic.c
trunk/launchd/src/launchproxy.c
Modified: trunk/launchd/src/launchctl.c
===================================================================
--- trunk/launchd/src/launchctl.c 2007-09-14 18:45:29 UTC (rev 23387)
+++ trunk/launchd/src/launchctl.c 2007-09-14 20:25:43 UTC (rev 23388)
@@ -3054,8 +3054,8 @@
}
if (fstat(fd, &sb) != -1) {
- if ((junkbuf = malloc(sb.st_size)) != NULL) {
- assumes(read(fd, junkbuf, sb.st_size) == sb.st_size);
+ if ((sb.st_size < 10*1024*1024) && (junkbuf = malloc((size_t)sb.st_size)) != NULL) {
+ assumes(read(fd, junkbuf, (size_t)sb.st_size) == (ssize_t)sb.st_size);
free(junkbuf);
}
}
Modified: trunk/launchd/src/launchd_core_logic.c
===================================================================
--- trunk/launchd/src/launchd_core_logic.c 2007-09-14 18:45:29 UTC (rev 23387)
+++ trunk/launchd/src/launchd_core_logic.c 2007-09-14 20:25:43 UTC (rev 23388)
@@ -2343,7 +2343,7 @@
td /= NSEC_PER_SEC;
if (j->start_time && (td < j->min_run_time) && !j->legacy_mach_job && !j->inetcompat) {
- time_t respawn_delta = j->min_run_time - td;
+ time_t respawn_delta = j->min_run_time - (uint32_t)td;
/*
* We technically should ref-count throttled jobs to prevent idle exit,
@@ -5898,7 +5898,7 @@
job_assumes(j, obj_at_idx = launch_data_array_get_index(out_obj_array, l2l_i));
job_assumes(j, tmp = launch_data_dict_lookup(obj_at_idx, TAKE_SUBSET_PID));
- target_pid = launch_data_get_integer(tmp);
+ target_pid = (pid_t)launch_data_get_integer(tmp);
job_assumes(j, tmp = launch_data_dict_lookup(obj_at_idx, TAKE_SUBSET_PERPID));
serv_perpid = launch_data_get_bool(tmp);
job_assumes(j, tmp = launch_data_dict_lookup(obj_at_idx, TAKE_SUBSET_NAME));
Modified: trunk/launchd/src/launchproxy.c
===================================================================
--- trunk/launchd/src/launchproxy.c 2007-09-14 18:45:29 UTC (rev 23387)
+++ trunk/launchd/src/launchproxy.c 2007-09-14 20:25:43 UTC (rev 23388)
@@ -108,7 +108,7 @@
tmp = launch_data_dict_lookup(resp, LAUNCH_JOBKEY_TIMEOUT);
if (tmp)
- timeout.tv_sec = launch_data_get_integer(tmp);
+ timeout.tv_sec = (int)launch_data_get_integer(tmp);
tmp = launch_data_dict_lookup(resp, LAUNCH_JOBKEY_PROGRAM);
if (tmp)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.macosforge.org/pipermail/launchd-changes/attachments/20070914/32308168/attachment.html
More information about the launchd-changes
mailing list