Skip to content

Commit dab712f

Browse files
committed
Fixed bug #8263 : gbak on classic with ParallelWorkers > 1 doesn't restore indices, giving a cryptic error message
1 parent 01b513d commit dab712f

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

src/jrd/idx.cpp

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -235,6 +235,10 @@ class IndexCreateTask : public Task
235235
if (att->att_parallel_workers > 0)
236236
workers = att->att_parallel_workers;
237237

238+
// Classic in single-user shutdown mode can't create additional worker attachments
239+
if ((m_dbb->dbb_ast_flags & DBB_shutdown_single) && !(m_dbb->dbb_flags & DBB_shared))
240+
workers = 1;
241+
238242
for (int i = 0; i < workers; i++)
239243
m_items.add(FB_NEW_POOL(*m_pool) Item(this));
240244

@@ -329,7 +333,9 @@ class IndexCreateTask : public Task
329333

330334
if (!att)
331335
{
332-
Arg::Gds(isc_bad_db_handle).copyTo(status);
336+
if (!status->hasData())
337+
Arg::Gds(isc_bad_db_handle).copyTo(status);
338+
333339
return false;
334340
}
335341

0 commit comments

Comments
 (0)