MCPcopy Create free account
hub / github.com/azadkuh/qhttp / prepareHeadersToWrite

Method prepareHeadersToWrite

src/qhttpserverresponse.cpp:73–85  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

71}
72
73void
74QHttpResponsePrivate::prepareHeadersToWrite() {
75
76 if ( !iheaders.contains("date") ) {
77 // Sun, 06 Nov 1994 08:49:37 GMT - RFC 822. Use QLocale::c() so english is used for month and
78 // day.
79 QString dateString = QLocale::c().
80 toString(QDateTime::currentDateTimeUtc(),
81 "ddd, dd MMM yyyy hh:mm:ss")
82 .append(" GMT");
83 addHeader("date", dateString.toLatin1());
84 }
85}
86
87///////////////////////////////////////////////////////////////////////////////
88} // namespace server

Callers

nothing calls this directly

Calls 1

toStringMethod · 0.80

Tested by

no test coverage detected