Skip to content

Commit

Permalink
Document why SP doesn't provide a .nop action
Browse files Browse the repository at this point in the history
  • Loading branch information
jvoisin committed Apr 1, 2020
1 parent aff65b2 commit 9462010
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions doc/source/faq.rst
Original file line number Diff line number Diff line change
Expand Up @@ -245,3 +245,19 @@ if someone can manage to get better results than us.
The possibility of having this natively in PHP has
`been discussed <https://marc.info/?l=php-internals&m=141692988212413&w=2>`_,
but as 2017, nothing has been merged yet.

Nop'ing function execution
""""""""""""""""""""""""""

Snuffleupagus can be configured to either *allow* or *drop* the execution of
particular functions and optionally *log* and *dump* them, but it doesn't
provide any mechanism to *nop* their execution.

We thought about adding this, but didn't for several reasons:

- What should the return value of a *nop'ed* function be?
- It would add confusion between ``drop``, ``nop`` and ``log``.
- Usually, when a specific function is called, either it's a dangerous one
and you want to stop the execution immediately, or you want to let it
continue and log it. There isn't really any middle-ground, or at least we
failed to find any.

0 comments on commit 9462010

Please sign in to comment.