Print this page
1730 DTrace should ignore type information from modules with cth_parlabel mismatches
Reviewed by: Keith Wesolowski <keith.wesolowski@joyent.com>
Reviewed by: Adam Leventhal <ahl@delphix.com>

Split Close
Expand all
Collapse all
          --- old/usr/src/common/ctf/ctf_open.c
          +++ new/usr/src/common/ctf/ctf_open.c
↓ open down ↓ 972 lines elided ↑ open up ↑
 973  973   * Return the name of the parent CTF container, if one exists.  Otherwise
 974  974   * return NULL to indicate this container is a root container.
 975  975   */
 976  976  const char *
 977  977  ctf_parent_name(ctf_file_t *fp)
 978  978  {
 979  979          return (fp->ctf_parname);
 980  980  }
 981  981  
 982  982  /*
      983 + * Return the label of the parent CTF container, if one exists.  Otherwise
      984 + * return NULL.
      985 + */
      986 +const char *
      987 +ctf_parent_label(ctf_file_t *fp)
      988 +{
      989 +        return (fp->ctf_parlabel);
      990 +}
      991 +
      992 +/*
 983  993   * Import the types from the specified parent container by storing a pointer
 984  994   * to it in ctf_parent and incrementing its reference count.  Only one parent
 985  995   * is allowed: if a parent already exists, it is replaced by the new parent.
 986  996   */
 987  997  int
 988  998  ctf_import(ctf_file_t *fp, ctf_file_t *pfp)
 989  999  {
 990 1000          if (fp == NULL || fp == pfp || (pfp != NULL && pfp->ctf_refcnt == 0))
 991 1001                  return (ctf_set_errno(fp, EINVAL));
 992 1002  
↓ open down ↓ 53 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX