GPG Password checker throws error only when process has not been terminated
diff --git a/dev-tools/scripts/buildAndPushRelease.py b/dev-tools/scripts/buildAndPushRelease.py
index 7044e43..1143ebf 100644
--- a/dev-tools/scripts/buildAndPushRelease.py
+++ b/dev-tools/scripts/buildAndPushRelease.py
@@ -54,7 +54,7 @@
       p.stdin.write('\n'.encode('UTF-8'))
 
   result = p.poll()
-  if result != 0:
+  if result is not None:
     msg = '    FAILED: %s [see log %s]' % (command, LOG)
     print(msg)
     raise RuntimeError(msg)