Commit 2317b255 authored by Stephen R. van den Berg's avatar Stephen R. van den Berg

Stdio.Buffer: Use PIKE_TYPEOF() macro.

parent 73003705
...@@ -455,7 +455,7 @@ PIKECLASS Buffer ...@@ -455,7 +455,7 @@ PIKECLASS Buffer
PMOD_EXPORT void io_actually_trigger_output( Buffer *io ) PMOD_EXPORT void io_actually_trigger_output( Buffer *io )
{ {
if (io->output.tu.named_type == PIKE_T_FUNCTION) { if (PIKE_TYPEOF(io->output) == PIKE_T_FUNCTION) {
if (UNLIKELY(!io->output.u.object->prog)) { if (UNLIKELY(!io->output.u.object->prog)) {
/* Destructed object. */ /* Destructed object. */
free_svalue(&io->output); free_svalue(&io->output);
...@@ -994,7 +994,7 @@ PIKECLASS Buffer ...@@ -994,7 +994,7 @@ PIKECLASS Buffer
if (f) if (f)
assign_svalue(&io->output, f); assign_svalue(&io->output, f);
else { else {
if (io->output.tu.named_type == PIKE_T_FUNCTION) if (PIKE_TYPEOF(io->output) == PIKE_T_FUNCTION)
free_svalue(&io->output); free_svalue(&io->output);
} }
} }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment