diff --git a/src/zipr.cpp b/src/zipr.cpp index bb84e91e0233992dcebb41570722a1833b1eec4f..3c4ad0db38ed52d13b7a0c1cfd9f64226d6efe1f 100644 --- a/src/zipr.cpp +++ b/src/zipr.cpp @@ -156,7 +156,10 @@ ZiprOptionsNamespace_t *ZiprImpl_t::RegisterOptions(ZiprOptionsNamespace_t *glob m_callbacks.SetDescription("Set the path of the file " "which contains any required callbacks."); m_seed.SetDescription("Seed the random number generator with this value."); - m_seed.SetValue((int)time(NULL)); + + // our pid is a fine default value -- had issues with time(NULL) as two copies of zipr from + // were getting the same time(NULL) return value since we invoked them in parallel. + m_seed.SetValue((int)getpid()); zipr_namespace->AddOption(&m_output_filename); zipr_namespace->AddOption(&m_callbacks);