Contents

SMJobRemove(_:_:_:_:_:)

Removes the job with the specified label from the specified domain.

Declaration

func SMJobRemove(_ domain: CFString!, _ jobLabel: CFString, _ auth: UnsafeMutableRawPointer!, _ wait: Bool, _ outError: UnsafeMutablePointer<Unmanaged<CFError>?>!) -> Bool
func SMJobRemove(_ domain: CFString!, _ jobLabel: CFString, _ auth: AuthorizationRef!, _ wait: Bool, _ outError: UnsafeMutablePointer<Unmanaged<CFError>?>!) -> Bool

Parameters

  • domain:

    The job’s domain (for example, Ksmdomainsystemlaunchd).

  • jobLabel:

    The label identifier of the job to remove.

  • auth:

    An AuthorizationRef containing the Ksmrightmodifysystemdaemons right if the specified domain is Ksmdomainsystemlaunchd.

  • wait:

    Pass true to block until the process for the specified job has exited.

  • outError:

    An output reference to a CFErrorRef describing the specific error when removing the job, or NULL if no error occurred. It’s the responsibility of the app to release the error reference. This argument can be NULL.

Return Value

Returns true if the system successfully removes the job, otherwise false.

Discussion

If the job is currently running, it conditionally blocks until the running process has exited.

See Also

Deprecated Functions