Revert "Redirect macro stack backtrace printing to debug log."
The rationale behind the change was to suppress the excessive output
when trying to expand a recursive macro definition (RhBug:613010) but
this is not so good as it effectively suppresses *all* backtrace output,
include those requested by %trace where the other half is printed to
stderr and the other half in the debug log because of the change.
Besides making things consistent, this also avoids deadlock on
`rpm -vv --eval '%trace'`.
This reverts commit 7f220202f2
.
Fixes: #1418
This commit is contained in:
parent
39595ccee3
commit
c145a6c86a
|
@ -358,7 +358,7 @@ static void
|
|||
printExpansion(MacroBuf mb, const char * t, const char * te)
|
||||
{
|
||||
if (!(te > t)) {
|
||||
rpmlog(RPMLOG_DEBUG, _("%3d<%*s(empty)\n"), mb->depth, (2 * mb->depth + 1), "");
|
||||
fprintf(stderr, _("%3d<%*s(empty)\n"), mb->depth, (2 * mb->depth + 1), "");
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -374,10 +374,10 @@ printExpansion(MacroBuf mb, const char * t, const char * te)
|
|||
|
||||
}
|
||||
|
||||
rpmlog(RPMLOG_DEBUG,"%3d<%*s", mb->depth, (2 * mb->depth + 1), "");
|
||||
fprintf(stderr, "%3d<%*s", mb->depth, (2 * mb->depth + 1), "");
|
||||
if (te > t)
|
||||
rpmlog(RPMLOG_DEBUG, "%.*s", (int)(te - t), t);
|
||||
rpmlog(RPMLOG_DEBUG, "\n");
|
||||
fprintf(stderr, "%.*s", (int)(te - t), t);
|
||||
fprintf(stderr, "\n");
|
||||
}
|
||||
|
||||
#define SKIPBLANK(_s, _c) \
|
||||
|
|
Loading…
Reference in New Issue