linuxmint/muffin — pull request #54 by autarkper (2012-11-23 08:40:09+00:00)
Title: [core/workspace.c] Make negative-workspace-index error recoverable.

Asking a deleted workspace for its index is an operation that will instantly kill Cinnamon. IMO that's an unacceptable outcome of a simple query, especially since there is no other easily discoverable method to validate a given workspace. This patch remedies the situation by simple letting the query function return a negative index instead of aborting.

The potential downside is that code that previously relied on the application aborting on a negative index will not continue executing, possibly leading to undefined behavior later on. The upside is that such undefined behavior can now be more easily debugged.