Commit c9e5f6b2 authored by Kurt Zeilenga's avatar Kurt Zeilenga
Browse files

Fix null pointer crash on NT

parent df92decb
......@@ -587,7 +587,7 @@ Re_write(
goto bad;
}
} else { /* write multiple "replica:" lines */
for ( i = 0; re->re_replicas[ i ].rh_hostname != NULL; i++ ) {
for ( i = 0; re->re_replicas && re->re_replicas[ i ].rh_hostname != NULL; i++ ) {
if ( fprintf( fp, "replica: %s:%d\n",
re->re_replicas[ i ].rh_hostname,
re->re_replicas[ i ].rh_port ) < 0 ) {
......
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