Print this page
11819 svcs -L should check for alt_logfile


2612 
2613         while ((ret = scf_iter_next_pg(pg_iter, g_pg)) == 1)
2614                 print_detailed_dependency(g_pg);
2615         if (ret == -1)
2616                 scfdie();
2617 
2618         scf_iter_destroy(pg_iter);
2619 
2620         if (opt_processes)
2621                 detailed_list_processes(wip);
2622 
2623         /* "application" type property groups */
2624         if (opt_verbose == 1)
2625                 print_application_properties(wip, snap);
2626 
2627         scf_snapshot_destroy(snap);
2628 
2629         return (0);
2630 }
2631 
2632 /* ARGSUSED */
2633 static int
2634 print_log(void *unused, scf_walkinfo_t *wip)
2635 {
2636         scf_propertygroup_t *rpg;
2637         char buf[MAXPATHLEN];
2638 
2639         if ((rpg = scf_pg_create(h)) == NULL)
2640                 scfdie();
2641 
2642         if (scf_instance_get_pg(wip->inst, SCF_PG_RESTARTER, rpg) != 0) {
2643                 if (scf_error() != SCF_ERROR_NOT_FOUND)
2644                         scfdie();
2645 
2646                 goto out;
2647         }
2648 
2649         if (pg_get_single_val(rpg, SCF_PROPERTY_LOGFILE,
2650             SCF_TYPE_ASTRING, buf, sizeof (buf), 0) == 0) {
2651                 (void) printf("%s\n", buf);



2652         }
2653 
2654 out:
2655         scf_pg_destroy(rpg);
2656 
2657         return (0);
2658 }
2659 
2660 int
2661 qsort_str_compare(const void *p1, const void *p2)
2662 {
2663         return (strcmp((const char *)p1, (const char *)p2));
2664 }
2665 
2666 /*
2667  * get_notify_param_classes()
2668  * return the fma classes that don't have a tag in fma_tags[], otherwise NULL
2669  */
2670 static char **
2671 get_notify_param_classes()




2612 
2613         while ((ret = scf_iter_next_pg(pg_iter, g_pg)) == 1)
2614                 print_detailed_dependency(g_pg);
2615         if (ret == -1)
2616                 scfdie();
2617 
2618         scf_iter_destroy(pg_iter);
2619 
2620         if (opt_processes)
2621                 detailed_list_processes(wip);
2622 
2623         /* "application" type property groups */
2624         if (opt_verbose == 1)
2625                 print_application_properties(wip, snap);
2626 
2627         scf_snapshot_destroy(snap);
2628 
2629         return (0);
2630 }
2631 

2632 static int
2633 print_log(void *unused __unused, scf_walkinfo_t *wip)
2634 {
2635         scf_propertygroup_t *rpg;
2636         char buf[MAXPATHLEN];
2637 
2638         if ((rpg = scf_pg_create(h)) == NULL)
2639                 scfdie();
2640 
2641         if (scf_instance_get_pg(wip->inst, SCF_PG_RESTARTER, rpg) != 0) {
2642                 if (scf_error() != SCF_ERROR_NOT_FOUND)
2643                         scfdie();
2644 
2645                 goto out;
2646         }
2647 
2648         if (pg_get_single_val(rpg, SCF_PROPERTY_LOGFILE,
2649             SCF_TYPE_ASTRING, buf, sizeof (buf), 0) == 0) {
2650                 (void) printf("%s\n", buf);
2651         } else if (pg_get_single_val(rpg, SCF_PROPERTY_ALT_LOGFILE,
2652             SCF_TYPE_ASTRING, buf, sizeof (buf), 0) == 0) {
2653                 (void) printf("%s\n", buf);
2654         }
2655 
2656 out:
2657         scf_pg_destroy(rpg);
2658 
2659         return (0);
2660 }
2661 
2662 int
2663 qsort_str_compare(const void *p1, const void *p2)
2664 {
2665         return (strcmp((const char *)p1, (const char *)p2));
2666 }
2667 
2668 /*
2669  * get_notify_param_classes()
2670  * return the fma classes that don't have a tag in fma_tags[], otherwise NULL
2671  */
2672 static char **
2673 get_notify_param_classes()