"OR and "AND" question

If you used { and } with every if statement, you'd know the answer.

  if(pingRet)
  { // Failure  //////////// I want this to be OR by here
    if(pingRet2) // Failure
    {
      pingSuccess();
    }
  }

Both pingRet and pingRet2 must be true for pingSuccess to be called.

Of course, you can combine them into one statement, using either && (and) or || (or), whichever meets your needs:

  if(pingRet && pingRet2)
  {
     // Both must be true to get here
  }

  if(pingRet || pingRet2)
  {
     // Either one of the statements being true will get to here
  }