summaryrefslogtreecommitdiff
path: root/src/include/mime-utils.h
blob: 732234a38e8f1975a20adb2d0ef6cba8a53e49d0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
/** --------------------------------------------------------------------
 *  @file  mime.cc
 *  @brief Implementation of main mime parser components
 *  @author Andreas Aardal Hanssen
 *  @date 2002-2005
 *  -----------------------------------------------------------------  **/
#ifndef mime_utils_h_included
#define mime_utils_h_included

#include <string.h>
#include <ctype.h>
#include <stdio.h>
#include <errno.h>

using namespace ::std;

inline bool compareStringToQueue(const char *s_in, char *bqueue,
                                 int pos, int size)
{
  for (int i = 0; i < size; ++i)
    if (s_in[i] != bqueue[(pos + i) % size])
      return false;

  return true;
}

#endif