Pergunta

I'm guessing the {} expansion results in something like

_() _  _()_&; _

but I would appreciate if a BASH guru chimed in and explained those characters chaining actions.

Foi útil?

Solução

It's the classic fork bomb: it defines a function named _ that calls itself twice (once in the foreground and once in the background) and calls it:

bomb(){ bomb | bomb &}; bomb

bomb() {
    bomb | bomb&
};

bomb

http://en.wikipedia.org/wiki/Fork_bomb

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top