Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
linphone-desktop
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Administrator
linphone-desktop
Commits
d7bd0229
Commit
d7bd0229
authored
May 29, 2017
by
Ronan Abhamon
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix(src/app/logger/Logger): avoid useless var in release mode
parent
4939fadd
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
11 deletions
+8
-11
Utils.hpp
linphone-desktop/src/Utils.hpp
+0
-2
Logger.cpp
linphone-desktop/src/app/logger/Logger.cpp
+8
-9
No files found.
linphone-desktop/src/Utils.hpp
View file @
d7bd0229
...
...
@@ -28,8 +28,6 @@
// =============================================================================
class
QQuickWindow
;
namespace
Utils
{
inline
QString
linphoneStringToQString
(
const
std
::
string
&
string
)
{
return
QString
::
fromLocal8Bit
(
string
.
c_str
(),
static_cast
<
int
>
(
string
.
size
()));
...
...
linphone-desktop/src/app/logger/Logger.cpp
View file @
d7bd0229
...
...
@@ -121,23 +121,22 @@ void Logger::log (QtMsgType type, const QMessageLogContext &context, const QStri
}
else
return
;
const
char
*
context
_s
tr
=
""
;
const
char
*
context
S
tr
=
""
;
#ifdef QT_MESSAGELOGCONTEXT
QByteArray
context_arr
;
QByteArray
contextArr
;
{
const
char
*
file
=
context
.
file
;
const
char
*
pos
=
file
?
::
Utils
::
rstrstr
(
file
,
SRC_PATTERN
)
:
file
;
context
_a
rr
=
QStringLiteral
(
"%1:%2: "
)
context
A
rr
=
QStringLiteral
(
"%1:%2: "
)
.
arg
(
pos
?
pos
+
sizeof
(
SRC_PATTERN
)
-
1
:
file
)
.
arg
(
context
.
line
)
.
toLocal8Bit
();
context
_str
=
context_a
rr
.
constData
();
context
Str
=
contextA
rr
.
constData
();
}
#else
(
void
)
context
;
#endif // ifdef QT_MESSAGELOGCONTEXT
QByteArray
localMsg
=
msg
.
toLocal8Bit
();
...
...
@@ -145,8 +144,8 @@ void Logger::log (QtMsgType type, const QMessageLogContext &context, const QStri
mMutex
.
lock
();
fprintf
(
stderr
,
format
,
dateTime
.
constData
(),
QThread
::
currentThread
(),
context
_s
tr
,
localMsg
.
constData
());
bctbx_log
(
QT_DOMAIN
,
level
,
"QT: %s%s"
,
context
_s
tr
,
localMsg
.
constData
());
fprintf
(
stderr
,
format
,
dateTime
.
constData
(),
QThread
::
currentThread
(),
context
S
tr
,
localMsg
.
constData
());
bctbx_log
(
QT_DOMAIN
,
level
,
"QT: %s%s"
,
context
S
tr
,
localMsg
.
constData
());
mMutex
.
unlock
();
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment