]> git.ipfire.org Git - thirdparty/squid.git/blame - src/ipc/FdNotes.cc
SourceFormat Enforcement
[thirdparty/squid.git] / src / ipc / FdNotes.cc
CommitLineData
0d0bce6a 1/*
bde978a6 2 * Copyright (C) 1996-2015 The Squid Software Foundation and contributors
0d0bce6a 3 *
bbc27441
AJ
4 * Squid software is distributed under GPLv2+ license and includes
5 * contributions from numerous individuals and organizations.
6 * Please see the COPYING and CONTRIBUTORS files for details.
0d0bce6a
AR
7 */
8
bbc27441
AJ
9/* DEBUG: section 54 Interprocess Communication */
10
f7f3304a 11#include "squid.h"
0d0bce6a
AR
12#include "Debug.h"
13#include "ipc/FdNotes.h"
14
0d0bce6a
AR
15const char *
16Ipc::FdNote(int fdNoteId)
17{
18 static const char *FdNotes[Ipc::fdnEnd] = {
19 "None", // fdnNone
00516be1 20 "HTTP Socket", // fdnHttpSocket
7b1e5eb4 21 "HTTPS Socket", // fdnHttpsSocket
434a79b0 22 "FTP Socket", // fdnFtpSocket
f738d783 23#if SQUID_SNMP
7b1e5eb4 24 "Incoming SNMP Socket", // fdnInSnmpSocket
013e320c 25 "Outgoing SNMP Socket", // fdnOutSnmpSocket
f738d783 26#endif
013e320c
AR
27 "Incoming ICP Socket", // fdnInIcpSocket
28 "Incoming HTCP Socket" // fdnInHtcpSocket
0d0bce6a
AR
29 };
30
31 if (fdnNone < fdNoteId && fdNoteId < fdnEnd)
32 return FdNotes[fdNoteId];
33
e0236918 34 debugs(54, DBG_IMPORTANT, HERE << "salvaged bug: wrong fd_note ID: " << fdNoteId);
0d0bce6a
AR
35 return FdNotes[fdnNone];
36}
f53969cc 37