Commit 94ab6a31 authored by Howard Chu's avatar Howard Chu
Browse files

ITS#6038 revert prev commits, ITS rejected

parent c8cf2fc4
......@@ -214,7 +214,7 @@ text_open (void ** display_datap)
data->buffer_length = default_buffer_length;
data->buffer = calloc( 1, default_buffer_length );
assert( data->buffer != NULL );
data->output = stdout;
data->output = stderr;
*display_datap = data;
return 0;
}
......@@ -314,7 +314,6 @@ text_update (
(void) fprintf( data->output,
"\r%-79s",
data->buffer );
(void) fflush( data->output );
data->need_eol = 1;
return 0;
}
......
......@@ -76,7 +76,7 @@ slapadd( int argc, char **argv )
/* default "000" */
csnsid = 0;
if ( isatty (1) ) enable_meter = 1;
if ( isatty (2) ) enable_meter = 1;
slap_tool_init( progname, SLAPADD, argc, argv );
memset( &opbuf, 0, sizeof(opbuf) );
......@@ -506,7 +506,7 @@ slapadd( int argc, char **argv )
if ( !dryrun ) {
if ( enable_meter ) {
fprintf( stdout, "Closing DB..." );
fprintf( stderr, "Closing DB..." );
}
if( be->be_entry_close( be ) ) {
rc = EXIT_FAILURE;
......@@ -516,7 +516,7 @@ slapadd( int argc, char **argv )
be->be_sync( be );
}
if ( enable_meter ) {
fprintf( stdout, "\n" );
fprintf( stderr, "\n" );
}
}
......
Supports Markdown
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