aboutsummaryrefslogtreecommitdiffstats
path: root/lib/asn1/src/asn1_db.erl
diff options
context:
space:
mode:
authorBjörn Gustavsson <[email protected]>2016-08-12 12:03:30 +0200
committerBjörn Gustavsson <[email protected]>2016-08-12 12:03:30 +0200
commit7613ee0580b0536ad868e1314c70399cf5b264f3 (patch)
treef0813cd73ccd52c6a7a52e42bcfef528d5d24fa5 /lib/asn1/src/asn1_db.erl
parenta88ac9abceb661a8878b8e18379c5403c3e08074 (diff)
parent44a7132df73b49f36e418c2d225f9053ce0cb93e (diff)
downloadotp-7613ee0580b0536ad868e1314c70399cf5b264f3.tar.gz
otp-7613ee0580b0536ad868e1314c70399cf5b264f3.tar.bz2
otp-7613ee0580b0536ad868e1314c70399cf5b264f3.zip
Merge branch 'bjorn/asn1/support-parallel-build/OTP-13624' into maint
* bjorn/asn1/support-parallel-build/OTP-13624: asn1_test_lib: Compile ASN.1 modules in parallel Support 'make -j' when compiling ASN.1 modules
Diffstat (limited to 'lib/asn1/src/asn1_db.erl')
-rw-r--r--lib/asn1/src/asn1_db.erl4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/asn1/src/asn1_db.erl b/lib/asn1/src/asn1_db.erl
index 557eca0ffd..869ea310aa 100644
--- a/lib/asn1/src/asn1_db.erl
+++ b/lib/asn1/src/asn1_db.erl
@@ -106,7 +106,9 @@ loop(#state{parent = Parent, monitor = MRef, table = Table,
loop(State);
{save, OutFile, Mod} ->
[{_,Mtab}] = ets:lookup(Table, Mod),
- ok = ets:tab2file(Mtab, OutFile),
+ TempFile = OutFile ++ ".#temp",
+ ok = ets:tab2file(Mtab, TempFile),
+ ok = file:rename(TempFile, OutFile),
loop(State);
{From, {new, Mod, Erule}} ->
[] = ets:lookup(Table, Mod), %Assertion.