Handle a security exception thrown during initializing the
Processor iterator.
351025
private void handleException(String key, Exception e) {
        if (e != null) {
            log.error(key, e.getLocalizedMessage());
            throw new Abort(e);
        } else {
            log.error(key);
            throw new Abort();
        }
    }
603098
def security_iter(nodearr):
        
        assert nodearr.Name == 'securityData' and nodearr.IsArray
        for i in range(nodearr.NumValues):
            node = nodearr.GetValue(i)
            err = XmlHelper.get_security_error(node)
            result = (None, err) if err else (node, None)
            yield result
364029
public static void safelyIgnoreException(Throwable t)
    {
        if (t instanceof ThreadDeath)
        {
            throw (ThreadDeath) t;
        }

        if (t instanceof OutOfMemoryError)
        {
            throw (OutOfMemoryError) t;
        }

    }
314383
private void processPendingExceptionHandlerEntry(int astoreVar) {
        if (pendingExceptionHandlerTypeName != null) {
            Type exceptionType = Type.getObjectType(pendingExceptionHandlerTypeName);
            pendingExceptionHandlerTypeName = null;
            if (onExceptionHandlerEntry(exceptionType, astoreVar)) {
                visitFrameAfterOnExceptionHandlerEntry();
            }
        }
    }
474606
private boolean handleException(final Throwable t,
                                  final HttpServletResponse resp,
                                  final boolean serverError) {
    if (serverError) {
      return true;
    }

    try {
      error(t);
      sendError(t, resp);
      return true;
    } catch (Throwable t1) {
      // Pretty much screwed if we get here
      return true;
    }
  }
1072235
private static void throwIOException(Exception mex, String sysId)
        throws IOException
    {
        String msg = "[resolving systemId '"+sysId+"']: "+mex.toString();
        throw ExceptionUtil.constructIOException(msg, mex);
    }
744073
private void init() {
        assertUnlocked();
        
        lock.lock();
        try {
            httpSender.init(cfg);

            LOG.info(
                "Starting with "
                    + DEFAULT_REQ_PROC_COUNT + " request processors");

            procThreads = new RequestProcessor[DEFAULT_REQ_PROC_COUNT];

            for (int i = 0; i < procThreads.length; i++) {
                procThreads[i] = new RequestProcessor(i);
                procThreads[i].start();
            }

        } finally {
            lock.unlock();
        }
    }
1153671
def _maybe_wrap_exception(exception):
    """"""
    if isinstance(exception, grpc.RpcError):
        return exceptions.from_grpc_error(exception)
    return exception
608416
private void handleExceptionThrown(Context cx, Throwable ex,
                                         StackFrame frame) {
        if (breakOnExceptions) {
            ContextData cd = frame.contextData();
            if (cd.lastProcessedException != ex) {
                interrupted(cx, frame, ex);
                cd.lastProcessedException = ex;
            }
        }
    }
1063123
public void init() throws Exception {
    // configure the SSLContext with a TrustManager
    SSLContext ctx = SSLContext.getInstance("TLS");
    if (ignoreCertificates) {
      ctx.init(new KeyManager[0],
          new TrustManager[] { new DefaultTrustManager() }, new SecureRandom());
      SSLContext.setDefault(ctx);
    }
    HostnameVerifier hv = new IgnoreHostName();
    HttpsURLConnection.setDefaultHostnameVerifier(hv);
  }
1060627
protected void handleError(Error error) throws Exception {
    String errMsg="error: "+error.getCode()+" info: "+error.getInfo();
    handleError(errMsg);
  }
343946
def handle_exception(exception)
      case exception
      when HamlLint::Exceptions::ConfigurationError
        log.error exception.message
        Sysexits::EX_CONFIG
      when HamlLint::Exceptions::InvalidCLIOption
        log.error exception.message
        log.log "Run `#{APP_NAME}` --help for usage documentation"
        Sysexits::EX_USAGE
      when HamlLint::Exceptions::InvalidFilePath
        log.error exception.message
        Sysexits::EX_NOINPUT
      when HamlLint::Exceptions::NoLintersError
        log.error exception.message
        Sysexits::EX_NOINPUT
      else
        print_unexpected_exception(exception)
        Sysexits::EX_SOFTWARE
      end
    end
591551
@Private
  @Override
  public void threwException(final int pTaskletId, final Exception exception) {
    assert taskletId == pTaskletId;

    this.userException = exception;
    if (callbackHandler != null) {
      executor.execute(new Runnable() {
        @Override
        public void run() {
          callbackHandler.onFailure(exception);
        }
      });
    }
    this.countDownLatch.countDown();
  }
180389
protected void handleException(final Exception e) {
        if (_swallowException) {
            _logger.warn("Metrics collection failed.", e);
        } else {
            if (e instanceof RuntimeException) {
                throw (RuntimeException) e;
            } else {
                throw new RuntimeException(e);
            }
        }
    }
374321
public void setException(Throwable exception) {
    this.exception = exception;

    if (handlers != null) {
      for (IsSimplePromiseResponseHandler<T> h : handlers) {
        h.onResponse(this);
      }
    }
  }
749892
void handleBreach(Exception e, Class[] classesStack) {
        String subject = "Izou Security Exception: " + e.getMessage();
        sendErrorReport(subject, e, classesStack);
    }
637932
def handle_exception (self):
        
        etype, evalue = sys.exc_info()[:2]
        log.debug(LOG_CHECK, "Error in %s: %s %s", self.url, etype, evalue, exception=True)
        # note: etype must be the exact class, not a subclass
        if (etype in ExcNoCacheList) or \
           (etype == socket.error and evalue.args[0]==errno.EBADF) or \
            not evalue:
            # EBADF occurs when operating on an already socket
            self.caching = False
        # format unicode message "<exception name>: <error message>"
        errmsg = unicode(etype.__name__)
        uvalue = strformat.unicode_safe(evalue)
        if uvalue:
            errmsg += u": %s" % uvalue
        # limit length to 240
        return strformat.limit(errmsg, length=240)