]> git.saurik.com Git - apple/syslog.git/blobdiff - syslogd.tproj/syslogd.c
syslog-356.50.1.tar.gz
[apple/syslog.git] / syslogd.tproj / syslogd.c
index f5c3f54b5fbcae13141aed8987df5811e536590c..2d45dc5839118d943a4385695ccfa8934f05b0c6 100644 (file)
@@ -48,8 +48,8 @@
 #include <notify.h>
 #include <notify_keys.h>
 #include <utmpx.h>
-#include <vproc_priv.h>
 #include <asl_private.h>
+
 #if !TARGET_OS_IPHONE
 #include <quarantine.h>
 #endif
@@ -65,8 +65,6 @@
 
 #define NOTIFY_DELAY 1
 
-#define forever for(;;)
-
 extern int _malloc_no_asl_log;
 
 #if TARGET_IPHONE_SIMULATOR
@@ -483,18 +481,6 @@ main(int argc, const char *argv[])
        }
 #endif
 
-#if TARGET_OS_IPHONE
-       /*
-        * Reset owner, group, and permissions in /var/mobile/Library/Logs
-        * in case something created them incorrectly.  syslogd was
-        * guilty of this in the past, creating them with owner root.
-        */
-
-       asl_secure_chown_chmod_dir("/private/var/mobile/Library/Logs", 501, 501, 0755);
-       asl_secure_chown_chmod_dir("/private/var/mobile/Library/Logs/CrashReporter", 501, 501, 0755);
-       asl_secure_chown_chmod_dir("/private/var/mobile/Library/Logs/CrashReporter/DiagnosticLogs", 501, 501, 0755);
-#endif
-
        /* Set I/O policy */
        setiopolicy_np(IOPOL_TYPE_DISK, IOPOL_SCOPE_PROCESS, IOPOL_PASSIVE);
 
@@ -732,19 +718,6 @@ main(int argc, const char *argv[])
                dispatch_resume(global.mark_timer);
        }
 
-#if !TARGET_IPHONE_SIMULATOR
-       asldebug("starting launchd input channel\n");
-       /*
-        * Start launchd service
-        * This pins a thread in _vprocmgr_log_drain.  Eventually we will either
-        * remove the whole stderr/stdout -> ASL mechanism entirely, or come up 
-        * with a communication channel that we can trigger with a dispatch source.
-        */
-       dispatch_async(dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_DEFAULT, 0), ^{
-               forever _vprocmgr_log_drain(NULL, NULL, launchd_callback);
-       });
-#endif
-
        asldebug("starting mach service\n");
        /*
         * Start mach server