Opened 9 years ago

Last modified 9 years ago

#9649 new Bugs

boost_interprocess, Win32: apps built with boost <1.54 remove temp files from apps >=1.54 (and vice versa)

Reported by: frank.richter@… Owned by: Ion Gaztañaga
Milestone: To Be Determined Component: interprocess
Version: Boost 1.54.0 Severity: Problem
Keywords: Cc:

Description

In boost 1.54, the format of the interprocess temporary file name changed (previously something like 20140205173952.047159, now like 1391618455). Unfortunately, this means that the "clean out previous boot session directories" recognizes the respective other filename as an "old" filename, even though it really isn't. Suppose you create an interprocess object with "Kernel or Filesystem" or persistence in an app A build against boost 1.54. You store something in it, but close it with the intention of re-opening it later (the desired persistence allows for that). But you happen to start an app B build against pre-1.54 in the meantime ... this cleans out the temp dir, incorrectly discarding the interprocess objects A created earlier. The attached patch changes the temp dir name if the "new" format is used.

Attachments (2)

boost_interprocess_fix_temp_dir_conflict.patch (841 bytes ) - added by frank.richter@… 9 years ago.
Patch to fix different boost versions clearing out interprocess temp dir
boost_interprocess_custom_tmp_dir.patch (1.5 KB ) - added by frank.richter@… 9 years ago.
Allow fully custom interprocess temp dir name

Download all attachments as: .zip

Change History (4)

by frank.richter@…, 9 years ago

Patch to fix different boost versions clearing out interprocess temp dir

comment:1 by frank.richter@…, 9 years ago

Summary: boost_interprocess, Win32: apps build with boost <1.54 remove temp files from apps >=1.54 (and vice versa)boost_interprocess, Win32: apps built with boost <1.54 remove temp files from apps >=1.54 (and vice versa)

comment:2 by Ion Gaztañaga, 9 years ago

Thanks for the report. Apart from the patch, I think the library should offer a way to specify the name of the subdirectory. A simple configurable macro should do the trick.

by frank.richter@…, 9 years ago

Allow fully custom interprocess temp dir name

Note: See TracTickets for help on using tickets.