Back to index

lightning-sunbird  0.9+nobinonly
Defines | Functions
nsURLParsers.cpp File Reference
#include <string.h>
#include "nsURLParsers.h"
#include "nsURLHelper.h"
#include "nsIURI.h"
#include "prtypes.h"
#include "nsString.h"
#include "nsCRT.h"
#include "netCore.h"

Go to the source code of this file.

Defines

#define SET_RESULT(component, pos, len)
#define OFFSET_RESULT(component, offset)

Functions

static PRUint32 CountConsecutiveSlashes (const char *str, PRInt32 len)

Define Documentation

#define OFFSET_RESULT (   component,
  offset 
)
Value:
PR_BEGIN_MACRO \
        if (component ## Pos) \
           *component ## Pos += offset; \
    PR_END_MACRO

Definition at line 75 of file nsURLParsers.cpp.

#define SET_RESULT (   component,
  pos,
  len 
)
Value:
PR_BEGIN_MACRO \
        if (component ## Pos) \
           *component ## Pos = PRUint32(pos); \
        if (component ## Len) \
           *component ## Len = PRInt32(len); \
    PR_END_MACRO

Definition at line 67 of file nsURLParsers.cpp.


Function Documentation

static PRUint32 CountConsecutiveSlashes ( const char *  str,
PRInt32  len 
) [static]

Definition at line 51 of file nsURLParsers.cpp.

{
    PRUint32 count = 0;
    while (len-- && *str++ == '/') ++count;
    return count;
}

Here is the caller graph for this function: