Fresh IDE . Artifact [c8c3efca52]
Not logged in

This repository is a mirror!

The original is located on: https://fresh.flatassembler.net/fossil/repo/fresh
If you want to follow the project, please update your remote-url

Artifact c8c3efca5220f7837073409bf34255e0408955d6:


 
<html><head><meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title></title><style type="text/css">
<!--
.style1 {font-size: 18px;font-weight: bold;font-family: Georgia, "Times New Roman", Times, serif;}
.style2 {font-size: 14px}
a{color:#0000cc;text-decoration:none}
a:visited{color:#0000cc;text-decoration:none}
.style3 {color: #660000}
-->
</style></head>
<body style="margin:0px 0px 0px 0px;">
<table width="100%" border="0" cellpadding="0" cellspacing="0">
  <tr>
    <td bgcolor="#cccccc"><span class="style1" style="margin-left:5px">sys_prctl &nbsp;<span class="style2">[kernel/sys.c] </span></span></td>
  </tr>
  <tr>
    <td><p style="margin-left:22px;margin-top:0px"><br />
      Performs operations on a process. </p>
      <p style="margin-left:10px"><strong>Arguments</strong></p>
      <table width="100%" border="0" style="margin-left:20px; margin-right:20px">
        <tr>
          <td width="6%" valign="top"><em>eax</em></td>
          <td width="94%">172</td>
        </tr>
        <tr>
          <td valign="top"><em>ebx</em></td>
          <td>Operation to perform. It may be one of the following: 
            <table width="100%" border="0" style="border:dashed;border-bottom-width:1px;border-left-width:1px;border-right-width:1px;border-top-width:1px;border-color:#333333">
              <tr>
                <td><table width="100%" border="0">
                    <tr>
                      <td width="17%" valign="top"><code>PR_SET_PDEATHSIG</code></td>
                      <td width="83%"><code>Set the parent process death signal of the current process   to the value specified by <em>ecx</em> (either a signal value in the range 1..maxsig, or 0 to clear).   This is the signal that the current process will get when its parent dies. This   value is cleared upon a <a href="002.html">sys_fork</a>. <br />
                        sys_prctl will fail with -EINVAL if the signal value specified in <em>ecx</em> is invalid. <br />    
                      <em>edx</em>, <em>esi</em>, and <em>edi</em> are ignored. </code></td>
                    </tr>
                    <tr>
                      <td valign="top"><code>PR_GET_PDEATHSIG</code></td>
                      <td><code>Read the current value of the parent process death signal   into the the address pointed by <em>ecx</em>. <em>edx</em>, <em>esi</em>, and <em>edi</em> are ignored.</code></td>
                    </tr>
                    <tr>
                      <td valign="top"><code>PR_GET_DUMPABLE</code></td>
                      <td><code>Return  the current state of the   calling process's dumpable flag. <em>ecx, edx</em>, <em>esi</em>, and <em>edi</em> are ignored.</code></td>
                    </tr>
                    <tr>
                      <td valign="top"><code>PR_SET_DUMPABLE</code></td>
                      <td><code>Set the state of the flag determining whether core dumps are   produced for this process upon delivery of a signal whose default behavior is   to produce a core dump. (Normally this flag is set for a process by default, but   it is cleared when a set-user-ID or set-group-ID program is executed and also by   various system calls that manipulate process UIDs and GIDs). In kernels up to   and including 2.6.12, <em>ecx</em> must be either 0 (process is not dumpable) or   1 (process is dumpable).<br />
                        sys_prctl will fail with -EINVAL if  <em>ecx</em> is negative or &gt; 1.<br />
                      <em>edx</em>, <em>esi</em>, and <em>edi</em> are ignored.</code></td>
                    </tr>
                    <tr>
                      <td valign="top"><code>PR_GET_KEEPCAPS</code></td>
                      <td><code>Return  the current state of the calling process's &quot;keep   capabilities&quot; flag. <br />  
                        <em>ecx, edx</em>, <em>esi</em>, and <em>edi</em> are ignored.</code></td>
                    </tr>
                    <tr>
                      <td valign="top"><code>PR_SET_KEEPCAPS</code></td>
                      <td><code>Set the state of the process's &quot;keep capabilities&quot; flag, which determines   whether the process's effective and permitted capability sets are cleared when a   change is made to the process's user IDs such that the process's real UID,   effective UID, and saved set-user-ID all become non-zero when at least one of   them previously had the value 0. (By default, these credential sets are   cleared). <em>ecx</em> must be either 0 (capabilities are cleared) or 1   (capabilities are kept). <br />
                        sys_prctl will fail with -EINVAL if <em>ecx</em> isn't  0 nor 1.<br />  
                      <em>edx</em>, <em>esi</em>, and <em>edi</em> are ignored.</code></td>
                    </tr>
                    <tr>
                      <td valign="top"><code>PR_SET_NAME</code></td>
                      <td><code><span class="style3">*to be documented* </span></code></td>
                    </tr>
                    <tr>
                      <td valign="top"><code>PR_GET_NAME</code></td>
                      <td><code><span class="style3">*to be documented* </span></code></td>
                    </tr>
                </table></td>
              </tr>
            </table></td>
        </tr>
        <tr>
          <td valign="top"><em>ecx</em></td>
          <td>This argument depends on a operation used. See above.</td>
        </tr>
        <tr>
          <td valign="top"><em>edx</em></td>
          <td>This argument depends on a operation used. See above. </td>
        </tr>
        <tr>
          <td valign="top"><em>esi</em></td>
          <td>This argument depends on a operation used. See above. </td>
        </tr>
        <tr>
          <td valign="top"><em>edi</em></td>
          <td>This argument depends on a operation used. See above. </td>
        </tr>
      </table>
      <p style="margin-left:10px" ><strong>Return values</strong></p>
      <p style="margin-left:22px;margin-right:10px" >If the system call succeeds the return value depends on the operation used. See above. <br />
If the system call fails the return value is either an operation specific error value (see above) or one of the following <em>errno</em> values:</p>
      <table width="100%" border="0" style="border:dashed;border-bottom-width:1px;border-left-width:1px;border-right-width:1px;border-top-width:1px;border-color:#333333;margin-left:22px;margin-right:22px">
        <tr>
          <td><table width="100%" border="0">
              <tr>
                <td width="10%" valign="top"><code>-EINVAL</code></td>
                <td width="90%"><code>The value of <em>ebx</em> is not recognized.</code></td>
              </tr>
          </table></td>
        </tr>
      </table>
      <p style="margin-left:10px"><strong>Remarks</strong></p>
      <p style="margin-left:22px">n/a</p>
      <p style="margin-left:10px"><strong>Compatibility</strong></p>
    <p style="margin-left:22px">n/a</p></td>
  </tr>
</table></body></html>