Question

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.

Was it helpful?

Solution

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

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top