qlocalserver_unix.cpp

Absolute File Name:/home/qt/qt5_coco/qt5/qtbase/src/network/socket/qlocalserver_unix.cpp
Switch to Source codePreprocessed file
LineSourceCount
1-
2-
3-
4-
5-
6-
7-
8-
9-
10-
11-
12-
13void QLocalServerPrivate::init()-
14{-
15}-
16-
17bool QLocalServerPrivate::removeServer(const QString &name)-
18{-
19 QString fileName;-
20 if (name.startsWith(QLatin1Char('/'))
name.startsWit...tin1Char('/'))Description
TRUEnever evaluated
FALSEevaluated 35 times by 2 tests
Evaluated by:
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
) {
0-35
21 fileName = name;-
22 }
never executed: end of block
else {
0
23 fileName = QDir::cleanPath(QDir::tempPath());-
24 fileName += QLatin1Char('/') + name;-
25 }
executed 35 times by 2 tests: end of block
Executed by:
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
35
26 if (QFile::exists(fileName)
QFile::exists(fileName)Description
TRUEevaluated 9 times by 1 test
Evaluated by:
  • tst_qlocalsocket - unknown status
FALSEevaluated 26 times by 2 tests
Evaluated by:
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
)
9-26
27 return
executed 9 times by 1 test: return QFile::remove(fileName);
Executed by:
  • tst_qlocalsocket - unknown status
QFile::remove(fileName);
executed 9 times by 1 test: return QFile::remove(fileName);
Executed by:
  • tst_qlocalsocket - unknown status
9
28 else-
29 return
executed 26 times by 2 tests: return true;
Executed by:
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
true;
executed 26 times by 2 tests: return true;
Executed by:
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
26
30}-
31-
32bool QLocalServerPrivate::listen(const QString &requestedServerName)-
33{-
34 QLocalServer * const q = q_func();-
35-
36-
37 if (requestedServerName.startsWith(QLatin1Char('/'))
requestedServe...tin1Char('/'))Description
TRUEevaluated 1 time by 1 test
Evaluated by:
  • tst_qlocalsocket - unknown status
FALSEevaluated 47 times by 3 tests
Evaluated by:
  • tst_QNetworkReply
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
) {
1-47
38 fullServerName = requestedServerName;-
39 }
executed 1 time by 1 test: end of block
Executed by:
  • tst_qlocalsocket - unknown status
else {
1
40 fullServerName = QDir::cleanPath(QDir::tempPath());-
41 fullServerName += QLatin1Char('/') + requestedServerName;-
42 }
executed 47 times by 3 tests: end of block
Executed by:
  • tst_QNetworkReply
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
47
43 serverName = requestedServerName;-
44-
45 QByteArray encodedTempPath;-
46 const QByteArray encodedFullServerName = QFile::encodeName(fullServerName);-
47 QScopedPointer<QTemporaryDir> tempDir;-
48-
49-
50 if (socketOptions & QLocalServer::WorldAccessOption
socketOptions ...ldAccessOptionDescription
TRUEevaluated 4 times by 1 test
Evaluated by:
  • tst_qlocalsocket - unknown status
FALSEevaluated 44 times by 3 tests
Evaluated by:
  • tst_QNetworkReply
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
) {
4-44
51 QFileInfo serverNameFileInfo(fullServerName);-
52 tempDir.reset(new QTemporaryDir(serverNameFileInfo.absolutePath() + QLatin1Char('/')));-
53 if (!tempDir->isValid()
!tempDir->isValid()Description
TRUEnever evaluated
FALSEevaluated 4 times by 1 test
Evaluated by:
  • tst_qlocalsocket - unknown status
) {
0-4
54 setError(QLatin1String("QLocalServer::listen"));-
55 return
never executed: return false;
false;
never executed: return false;
0
56 }-
57 encodedTempPath = QFile::encodeName(tempDir->path() + QLatin1String("/s"));-
58 }
executed 4 times by 1 test: end of block
Executed by:
  • tst_qlocalsocket - unknown status
4
59-
60-
61 listenSocket = qt_safe_socket(1, SOCK_STREAM, 0);-
62 if (-
-1 == listenSocketDescription
TRUEnever evaluated
FALSEevaluated 48 times by 3 tests
Evaluated by:
  • tst_QNetworkReply
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
1 == listenSocket
-1 == listenSocketDescription
TRUEnever evaluated
FALSEevaluated 48 times by 3 tests
Evaluated by:
  • tst_QNetworkReply
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
) {
0-48
63 setError(QLatin1String("QLocalServer::listen"));-
64 closeServer();-
65 return
never executed: return false;
false;
never executed: return false;
0
66 }-
67-
68-
69 struct ::sockaddr_un addr;-
70 addr.sun_family = 1;-
71 if (sizeof(addr.sun_path) < (uint)encodedFullServerName.size() + 1
sizeof(addr.su...ame.size() + 1Description
TRUEevaluated 1 time by 1 test
Evaluated by:
  • tst_qlocalsocket - unknown status
FALSEevaluated 47 times by 3 tests
Evaluated by:
  • tst_QNetworkReply
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
) {
1-47
72 setError(QLatin1String("QLocalServer::listen"));-
73 closeServer();-
74 return
executed 1 time by 1 test: return false;
Executed by:
  • tst_qlocalsocket - unknown status
false;
executed 1 time by 1 test: return false;
Executed by:
  • tst_qlocalsocket - unknown status
1
75 }-
76-
77 if (socketOptions & QLocalServer::WorldAccessOption
socketOptions ...ldAccessOptionDescription
TRUEevaluated 4 times by 1 test
Evaluated by:
  • tst_qlocalsocket - unknown status
FALSEevaluated 43 times by 3 tests
Evaluated by:
  • tst_QNetworkReply
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
) {
4-43
78 if (sizeof(addr.sun_path) < (uint)encodedTempPath.size() + 1
sizeof(addr.su...ath.size() + 1Description
TRUEnever evaluated
FALSEevaluated 4 times by 1 test
Evaluated by:
  • tst_qlocalsocket - unknown status
) {
0-4
79 setError(QLatin1String("QLocalServer::listen"));-
80 closeServer();-
81 return
never executed: return false;
false;
never executed: return false;
0
82 }-
83 ::memcpy(addr.sun_path, encodedTempPath.constData(),-
84 encodedTempPath.size() + 1);-
85 }
executed 4 times by 1 test: end of block
Executed by:
  • tst_qlocalsocket - unknown status
else {
4
86 ::memcpy(addr.sun_path, encodedFullServerName.constData(),-
87 encodedFullServerName.size() + 1);-
88 }
executed 43 times by 3 tests: end of block
Executed by:
  • tst_QNetworkReply
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
43
89-
90-
91 if(-
-1 == ::bind(l...(sockaddr_un))Description
TRUEevaluated 1 time by 1 test
Evaluated by:
  • tst_qlocalsocket - unknown status
FALSEevaluated 46 times by 3 tests
Evaluated by:
  • tst_QNetworkReply
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
1 == ::bind(listenSocket, (sockaddr *)&addr, sizeof(sockaddr_un))
-1 == ::bind(l...(sockaddr_un))Description
TRUEevaluated 1 time by 1 test
Evaluated by:
  • tst_qlocalsocket - unknown status
FALSEevaluated 46 times by 3 tests
Evaluated by:
  • tst_QNetworkReply
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
) {
1-46
92 setError(QLatin1String("QLocalServer::listen"));-
93-
94 if((*
(*__errno_location ()) == 98Description
TRUEevaluated 1 time by 1 test
Evaluated by:
  • tst_qlocalsocket - unknown status
FALSEnever evaluated
__errno_location ()) == 98
(*__errno_location ()) == 98Description
TRUEevaluated 1 time by 1 test
Evaluated by:
  • tst_qlocalsocket - unknown status
FALSEnever evaluated
)
0-1
95 qt_safe_close(listenSocket);
executed 1 time by 1 test: qt_safe_close(listenSocket);
Executed by:
  • tst_qlocalsocket - unknown status
1
96-
97 else-
98 closeServer();
never executed: closeServer();
0
99 listenSocket = -1;-
100 return
executed 1 time by 1 test: return false;
Executed by:
  • tst_qlocalsocket - unknown status
false;
executed 1 time by 1 test: return false;
Executed by:
  • tst_qlocalsocket - unknown status
1
101 }-
102-
103-
104 if (-
-1 == qt_safe_...tenSocket, 50)Description
TRUEnever evaluated
FALSEevaluated 46 times by 3 tests
Evaluated by:
  • tst_QNetworkReply
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
1 == qt_safe_listen(listenSocket, 50)
-1 == qt_safe_...tenSocket, 50)Description
TRUEnever evaluated
FALSEevaluated 46 times by 3 tests
Evaluated by:
  • tst_QNetworkReply
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
) {
0-46
105 setError(QLatin1String("QLocalServer::listen"));-
106 closeServer();-
107 listenSocket = -1;-
108 if (error != QAbstractSocket::AddressInUseError
error != QAbst...ressInUseErrorDescription
TRUEnever evaluated
FALSEnever evaluated
)
0
109 QFile::remove(fullServerName);
never executed: QFile::remove(fullServerName);
0
110 return
never executed: return false;
false;
never executed: return false;
0
111 }-
112-
113 if (socketOptions & QLocalServer::WorldAccessOption
socketOptions ...ldAccessOptionDescription
TRUEevaluated 4 times by 1 test
Evaluated by:
  • tst_qlocalsocket - unknown status
FALSEevaluated 42 times by 3 tests
Evaluated by:
  • tst_QNetworkReply
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
) {
4-42
114 mode_t mode = 000;-
115-
116 if (socketOptions & QLocalServer::UserAccessOption
socketOptions ...erAccessOptionDescription
TRUEevaluated 2 times by 1 test
Evaluated by:
  • tst_qlocalsocket - unknown status
FALSEevaluated 2 times by 1 test
Evaluated by:
  • tst_qlocalsocket - unknown status
)
2
117 mode |= (0400|0200|0100);
executed 2 times by 1 test: mode |= (0400|0200|0100);
Executed by:
  • tst_qlocalsocket - unknown status
2
118-
119 if (socketOptions & QLocalServer::GroupAccessOption
socketOptions ...upAccessOptionDescription
TRUEevaluated 2 times by 1 test
Evaluated by:
  • tst_qlocalsocket - unknown status
FALSEevaluated 2 times by 1 test
Evaluated by:
  • tst_qlocalsocket - unknown status
)
2
120 mode |= ((0400|0200|0100) >> 3);
executed 2 times by 1 test: mode |= ((0400|0200|0100) >> 3);
Executed by:
  • tst_qlocalsocket - unknown status
2
121-
122 if (socketOptions & QLocalServer::OtherAccessOption
socketOptions ...erAccessOptionDescription
TRUEevaluated 2 times by 1 test
Evaluated by:
  • tst_qlocalsocket - unknown status
FALSEevaluated 2 times by 1 test
Evaluated by:
  • tst_qlocalsocket - unknown status
)
2
123 mode |= (((0400|0200|0100) >> 3) >> 3);
executed 2 times by 1 test: mode |= (((0400|0200|0100) >> 3) >> 3);
Executed by:
  • tst_qlocalsocket - unknown status
2
124-
125 if (::
::chmod(encode...), mode) == -1Description
TRUEnever evaluated
FALSEevaluated 4 times by 1 test
Evaluated by:
  • tst_qlocalsocket - unknown status
chmod(encodedTempPath.constData(), mode) == -1
::chmod(encode...), mode) == -1Description
TRUEnever evaluated
FALSEevaluated 4 times by 1 test
Evaluated by:
  • tst_qlocalsocket - unknown status
) {
0-4
126 setError(QLatin1String("QLocalServer::listen"));-
127 closeServer();-
128 return
never executed: return false;
false;
never executed: return false;
0
129 }-
130-
131 if (::
::rename(encod...tData()) == -1Description
TRUEnever evaluated
FALSEevaluated 4 times by 1 test
Evaluated by:
  • tst_qlocalsocket - unknown status
rename(encodedTempPath.constData(), encodedFullServerName.constData()) == -1
::rename(encod...tData()) == -1Description
TRUEnever evaluated
FALSEevaluated 4 times by 1 test
Evaluated by:
  • tst_qlocalsocket - unknown status
) {
0-4
132 setError(QLatin1String("QLocalServer::listen"));-
133 closeServer();-
134 return
never executed: return false;
false;
never executed: return false;
0
135 }-
136 }
executed 4 times by 1 test: end of block
Executed by:
  • tst_qlocalsocket - unknown status
4
137-
138 ((!(!socketNotifier)) ? qt_assert("!socketNotifier",__FILE__,187) : qt_noop());-
139 socketNotifier = new QSocketNotifier(listenSocket,-
140 QSocketNotifier::Read, q);-
141 q->connect(socketNotifier, qFlagLocation("2""activated(int)" "\0" __FILE__ ":" "190"),-
142 q, qFlagLocation("1""_q_onNewConnection()" "\0" __FILE__ ":" "191"));-
143 socketNotifier->setEnabled(maxPendingConnections > 0);-
144 return
executed 46 times by 3 tests: return true;
Executed by:
  • tst_QNetworkReply
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
true;
executed 46 times by 3 tests: return true;
Executed by:
  • tst_QNetworkReply
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
46
145}-
146-
147bool QLocalServerPrivate::listen(qintptr socketDescriptor)-
148{-
149 QLocalServer * const q = q_func();-
150-
151-
152 listenSocket = socketDescriptor;-
153-
154 ::fcntl(listenSocket, 2, 1);-
155 ::fcntl(listenSocket, 4, ::fcntl(listenSocket, 3) | 04000);-
156-
157-
158 struct ::sockaddr_un addr;-
159 socklen_t len = sizeof(addr);-
160 memset(&addr, 0, sizeof(addr));-
161 if (0 == ::getsockname(listenSocket, (sockaddr *)&addr, &len)
0 == ::getsock...*)&addr, &len)Description
TRUEevaluated 4 times by 1 test
Evaluated by:
  • tst_qlocalsocket - unknown status
FALSEnever evaluated
) {
0-4
162-
163 if (addr.sun_family == 1
addr.sun_family == 1Description
TRUEevaluated 4 times by 1 test
Evaluated by:
  • tst_qlocalsocket - unknown status
FALSEnever evaluated
&& addr.sun_path[0] == 0
addr.sun_path[0] == 0Description
TRUEevaluated 3 times by 1 test
Evaluated by:
  • tst_qlocalsocket - unknown status
FALSEevaluated 1 time by 1 test
Evaluated by:
  • tst_qlocalsocket - unknown status
) {
0-4
164 addr.sun_path[0] = '@';-
165 }
executed 3 times by 1 test: end of block
Executed by:
  • tst_qlocalsocket - unknown status
3
166 QString name = QString::fromLatin1(addr.sun_path);-
167 if (!name.isEmpty()
!name.isEmpty()Description
TRUEevaluated 4 times by 1 test
Evaluated by:
  • tst_qlocalsocket - unknown status
FALSEnever evaluated
) {
0-4
168 fullServerName = name;-
169 serverName = fullServerName.mid(fullServerName.lastIndexOf(QLatin1Char('/')) + 1);-
170 if (serverName.isEmpty()
serverName.isEmpty()Description
TRUEnever evaluated
FALSEevaluated 4 times by 1 test
Evaluated by:
  • tst_qlocalsocket - unknown status
) {
0-4
171 serverName = fullServerName;-
172 }
never executed: end of block
0
173 }
executed 4 times by 1 test: end of block
Executed by:
  • tst_qlocalsocket - unknown status
4
174 }
executed 4 times by 1 test: end of block
Executed by:
  • tst_qlocalsocket - unknown status
4
175-
176-
177-
178-
179-
180 ((!(!socketNotifier)) ? qt_assert("!socketNotifier",__FILE__,229) : qt_noop());-
181 socketNotifier = new QSocketNotifier(listenSocket,-
182 QSocketNotifier::Read, q);-
183 q->connect(socketNotifier, qFlagLocation("2""activated(int)" "\0" __FILE__ ":" "232"),-
184 q, qFlagLocation("1""_q_onNewConnection()" "\0" __FILE__ ":" "233"));-
185 socketNotifier->setEnabled(maxPendingConnections > 0);-
186 return
executed 4 times by 1 test: return true;
Executed by:
  • tst_qlocalsocket - unknown status
true;
executed 4 times by 1 test: return true;
Executed by:
  • tst_qlocalsocket - unknown status
4
187}-
188-
189-
190-
191-
192-
193-
194void QLocalServerPrivate::closeServer()-
195{-
196 if (socketNotifier
socketNotifierDescription
TRUEevaluated 50 times by 3 tests
Evaluated by:
  • tst_QNetworkReply
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
FALSEevaluated 1 time by 1 test
Evaluated by:
  • tst_qlocalsocket - unknown status
) {
1-50
197 socketNotifier->setEnabled(false);-
198 socketNotifier->deleteLater();-
199 socketNotifier = 0;-
200 }
executed 50 times by 3 tests: end of block
Executed by:
  • tst_QNetworkReply
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
50
201-
202 if (-
-1 != listenSocketDescription
TRUEevaluated 51 times by 3 tests
Evaluated by:
  • tst_QNetworkReply
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
FALSEnever evaluated
1 != listenSocket
-1 != listenSocketDescription
TRUEevaluated 51 times by 3 tests
Evaluated by:
  • tst_QNetworkReply
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
FALSEnever evaluated
)
0-51
203 qt_safe_close(listenSocket);
executed 51 times by 3 tests: qt_safe_close(listenSocket);
Executed by:
  • tst_QNetworkReply
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
51
204 listenSocket = -1;-
205-
206 if (!fullServerName.isEmpty()
!fullServerName.isEmpty()Description
TRUEevaluated 51 times by 3 tests
Evaluated by:
  • tst_QNetworkReply
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
FALSEnever evaluated
)
0-51
207 QFile::remove(fullServerName);
executed 51 times by 3 tests: QFile::remove(fullServerName);
Executed by:
  • tst_QNetworkReply
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
51
208}
executed 51 times by 3 tests: end of block
Executed by:
  • tst_QNetworkReply
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
51
209-
210-
211-
212-
213-
214-
215-
216void QLocalServerPrivate::_q_onNewConnection()-
217{-
218 QLocalServer * const q = q_func();-
219 if (-
-1 == listenSocketDescription
TRUEnever evaluated
FALSEevaluated 77 times by 3 tests
Evaluated by:
  • tst_QNetworkReply
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
1 == listenSocket
-1 == listenSocketDescription
TRUEnever evaluated
FALSEevaluated 77 times by 3 tests
Evaluated by:
  • tst_QNetworkReply
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
)
0-77
220 return;
never executed: return;
0
221-
222 ::sockaddr_un addr;-
223 socklen_t length = sizeof(sockaddr_un);-
224 int connectedSocket = qt_safe_accept(listenSocket, (sockaddr *)&addr, &length);-
225 if(-
-1 == connectedSocketDescription
TRUEnever evaluated
FALSEevaluated 77 times by 3 tests
Evaluated by:
  • tst_QNetworkReply
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
1 == connectedSocket
-1 == connectedSocketDescription
TRUEnever evaluated
FALSEevaluated 77 times by 3 tests
Evaluated by:
  • tst_QNetworkReply
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
) {
0-77
226 setError(QLatin1String("QLocalSocket::activated"));-
227 closeServer();-
228 }
never executed: end of block
else {
0
229 socketNotifier->setEnabled(pendingConnections.size()-
230 <= maxPendingConnections);-
231 q->incomingConnection(connectedSocket);-
232 }
executed 77 times by 3 tests: end of block
Executed by:
  • tst_QNetworkReply
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
77
233}-
234-
235void QLocalServerPrivate::waitForNewConnection(int msec, bool *timedOut)-
236{-
237 pollfd pfd = qt_make_pollfd(listenSocket, 0x001);-
238-
239 switch (qt_poll_msecs(&pfd, 1, msec)) {-
240 case
executed 2 times by 1 test: case 0:
Executed by:
  • tst_qlocalsocket - unknown status
0:
executed 2 times by 1 test: case 0:
Executed by:
  • tst_qlocalsocket - unknown status
2
241 if (timedOut
timedOutDescription
TRUEevaluated 2 times by 1 test
Evaluated by:
  • tst_qlocalsocket - unknown status
FALSEnever evaluated
)
0-2
242 *
executed 2 times by 1 test: *timedOut = true;
Executed by:
  • tst_qlocalsocket - unknown status
timedOut = true;
executed 2 times by 1 test: *timedOut = true;
Executed by:
  • tst_qlocalsocket - unknown status
2
243-
244 return;
executed 2 times by 1 test: return;
Executed by:
  • tst_qlocalsocket - unknown status
2
245 break;
dead code: break;
-
246 default
executed 77 times by 3 tests: default:
Executed by:
  • tst_QNetworkReply
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
:
executed 77 times by 3 tests: default:
Executed by:
  • tst_QNetworkReply
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
77
247 if ((
(pfd.revents & 0x020) == 0Description
TRUEevaluated 77 times by 3 tests
Evaluated by:
  • tst_QNetworkReply
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
FALSEnever evaluated
pfd.revents & 0x020) == 0
(pfd.revents & 0x020) == 0Description
TRUEevaluated 77 times by 3 tests
Evaluated by:
  • tst_QNetworkReply
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
FALSEnever evaluated
) {
0-77
248 _q_onNewConnection();-
249 return;
executed 77 times by 3 tests: return;
Executed by:
  • tst_QNetworkReply
  • tst_QNetworkSession
  • tst_qlocalsocket - unknown status
77
250 }-
251-
252 (*__errno_location ()) = 9;-
253-
254 case
never executed: case -1:
-1:
never executed: case -1:
code before this statement never executed: case -1:
0
255 setError(QLatin1String("QLocalServer::waitForNewConnection"));-
256 closeServer();-
257 break;
never executed: break;
0
258 }-
259}-
260-
261void QLocalServerPrivate::setError(const QString &function)-
262{-
263 if (11 == (*__errno_location ())
11 == (*__errno_location ())Description
TRUEnever evaluated
FALSEevaluated 2 times by 1 test
Evaluated by:
  • tst_qlocalsocket - unknown status
)
0-2
264 return;
never executed: return;
0
265-
266 switch ((*__errno_location ())) {-
267 case
never executed: case 13:
13:
never executed: case 13:
0
268 errorString = QLocalServer::tr("%1: Permission denied").arg(function);-
269 error = QAbstractSocket::SocketAccessError;-
270 break;
never executed: break;
0
271 case
never executed: case 40:
40:
never executed: case 40:
0
272 case
never executed: case 2:
2:
never executed: case 2:
0
273 case
executed 1 time by 1 test: case 36:
Executed by:
  • tst_qlocalsocket - unknown status
36:
executed 1 time by 1 test: case 36:
Executed by:
  • tst_qlocalsocket - unknown status
1
274 case
never executed: case 30:
30:
never executed: case 30:
0
275 case
never executed: case 20:
20:
never executed: case 20:
0
276 errorString = QLocalServer::tr("%1: Name error").arg(function);-
277 error = QAbstractSocket::HostNotFoundError;-
278 break;
executed 1 time by 1 test: break;
Executed by:
  • tst_qlocalsocket - unknown status
1
279 case
executed 1 time by 1 test: case 98:
Executed by:
  • tst_qlocalsocket - unknown status
98:
executed 1 time by 1 test: case 98:
Executed by:
  • tst_qlocalsocket - unknown status
1
280 errorString = QLocalServer::tr("%1: Address in use").arg(function);-
281 error = QAbstractSocket::AddressInUseError;-
282 break;
executed 1 time by 1 test: break;
Executed by:
  • tst_qlocalsocket - unknown status
1
283-
284 default
never executed: default:
:
never executed: default:
0
285 errorString = QLocalServer::tr("%1: Unknown error %2")-
286 .arg(function).arg((*__errno_location ()));-
287 error = QAbstractSocket::UnknownSocketError;-
288-
289-
290-
291 }
never executed: end of block
0
292}-
293-
294-
Switch to Source codePreprocessed file

Generated by Squish Coco Non-Commercial 4.3.0-BETA-master-30-08-2018-4cb69e9