mirror of
https://github.com/appium/appium.git
synced 2026-05-05 18:10:24 -05:00
fix async bug in ios crash waterfall
previously, we'd respond to the client's current callback and then start the shutdown sequence. this opened up a situation where the client could then call another command (say driver.quit) during shutdown, enabling the possibility of two simultaneous shutdown flows causing undefined behavior. this fix makes sure we don't respond to the client for a command that caused a crash until we're done shutting down.
This commit is contained in:
@@ -62,6 +62,9 @@ exports.getStatus = function (req, res) {
|
||||
if (typeof gitSha !== "undefined") {
|
||||
data.build.revision = gitSha;
|
||||
}
|
||||
if (req.device && typeof req.device.getStatusExtensions === "function") {
|
||||
data = _.extend(data, req.device.getStatusExtensions());
|
||||
}
|
||||
respondSuccess(req, res, data);
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user