Fixed am51051 - unpause() returning true on stopped plugins
This commit is contained in:
parent
06f01ea7dc
commit
fff603635a
@ -98,6 +98,7 @@ public:
|
||||
inline void setError(const char* n) { errorMsg.assign(n); }
|
||||
inline bool isValid() const { return (status >= ps_paused); }
|
||||
inline bool isPaused() const { return ((status == ps_paused) || (status == ps_stopped)); }
|
||||
inline bool isStopped() const { return (status == ps_stopped); }
|
||||
inline bool isExecutable(int id) const { return (isValid() && !isPaused()); }
|
||||
|
||||
void Finalize();
|
||||
|
@ -2453,7 +2453,7 @@ static cell AMX_NATIVE_CALL unpause(AMX *amx, cell *params) /* 3 param */
|
||||
else
|
||||
plugin = g_plugins.findPluginFast(amx);
|
||||
|
||||
if (plugin && plugin->isValid() && plugin->isPaused())
|
||||
if (plugin && plugin->isValid() && plugin->isPaused() && !plugin->isStopped())
|
||||
{
|
||||
plugin->unpausePlugin();
|
||||
return 1;
|
||||
|
Loading…
Reference in New Issue
Block a user