Only fork for peak building when necessary.
This commit is contained in:
parent
c8b872ae41
commit
9cbc39addd
|
@ -268,9 +268,10 @@ Peaks::open ( void )
|
||||||
|
|
||||||
int fd;
|
int fd;
|
||||||
|
|
||||||
|
if ( ! current() )
|
||||||
/* Build peaks asyncronously */
|
/* Build peaks asyncronously */
|
||||||
if ( ! fork() )
|
if ( ! fork() )
|
||||||
exit( make_peaks( 256 ) );
|
exit( make_peaks( 256 ) );
|
||||||
|
|
||||||
if ( ( fd = ::open( peakname( filename ), O_RDONLY ) ) < 0 )
|
if ( ( fd = ::open( peakname( filename ), O_RDONLY ) ) < 0 )
|
||||||
return false;
|
return false;
|
||||||
|
|
Loading…
Reference in New Issue