The critical option

You can use the critical option as a mechanism to clean up attributes on the abnormal termination of a publisher.

If you use this option when opening a file descriptor for a write, then when the file descriptor is closed, PPS deletes all nonpersistent attributes and prefixes an asterisk (“*”) to the object name in the notification string it sends to all subscribers. PPS does not provide a list of the deleted attributes.

Duplicate critical file descriptors

You should never have more than one critical file descriptor for any one PPS object.

File descriptors can be duplicated either explicitly (by dup(), dup2(), fcntl(), etc.) or implicitly (by fork(), spawn(), etc.). Duplicated descriptors in effect increment a reference count on the underlying critical descriptor. The behavior required of critical objects (the notification and deletion of volatile attributes) isn't triggered until the reference count for a file descriptor drops to zero, indicating that the original and all duplicates are closed.

However, if you open a PPS object more than once in critical mode, each file descriptor behaves as a critical descriptor: if the reference count of any one file descriptor drops to zero, the notification and deletion behavior is triggered for the object—even if other descriptors remain open.