function processFile (pcap, pos, i, nextCb) {
      pcap.ref();

      if (Config.debug > 2) {
        console.log('readPacket', pos);
      }
      pcap.readPacket(pos, (packet) => {
        switch (packet) {
        case null:
          const msg1 = util.format(session._id, 'in file', pcap.filename, "couldn't read packet at", pos, 'packet #', i, 'of', fields.packetPos.length);
          console.log('ERROR - processSessionIdDisk -', msg1);
          endCb(msg1, null);
          break;
        case undefined:
          break;
        default:
          packetCb(pcap, packet, nextCb, i);
          break;
        }
        pcap.unref();
      });
    }
Adds the view search expression to the elasticsearch query
@ignore
@name addViewToQuery
@param {object} req - the client request
@param {object} query - the elasticsearch query that has been partially built already by buildSessionQuery
@param {function} continueBuildQueryCb - the callback to call when adding the view is complete
@param {function} finalCb - the callback to pass to continueBuildQueryCb that is called when building the sessions query is complete
@param {boolean} queryOverride=null - override the client query with overriding query
@returns {function} - the callback to call once the session query is built or an error occurs