Quoting.cc File Reference
#include "squid.h"
#include "html/Quoting.h"
#include "sbuf/SBuf.h"
#include <array>
#include <cstring>
Include dependency graph for Quoting.cc:

Go to the source code of this file.

Functions

static const auto & EscapeSequences ()
 
char * html_quote (const char *string)
 

Function Documentation

◆ EscapeSequences()

static const auto& EscapeSequences ( )
static

Definition at line 17 of file Quoting.cc.

References SBuf::Printf().

Referenced by html_quote().

◆ html_quote()

char* html_quote ( const char *  )

Obtain a static buffer containing an HTML-encoded version of the given c-string.

HTML reserved characters are replaced with character references per https://html.spec.whatwg.org/#character-references

Definition at line 42 of file Quoting.cc.

References EscapeSequences(), xcalloc(), and xfree.

Referenced by ErrorState::compileLegacyCode(), Ftp::Gateway::htmlifyListEntry(), CommonNamesPrinter::matchDomainName(), Security::ErrorDetail::printCaName(), Security::ErrorDetail::printSubject(), and TestHtmlQuote::test_html_quote_cstr().

 

Introduction

Documentation

Support

Miscellaneous