Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(650)

Issue 319510043: Prevent race condition in font export directory making

Can't Edit
Can't Publish+Mail
Start Review
Created:
8 months, 1 week ago by trueroad
Modified:
8 months ago
Reviewers:
dak
CC:
lilypond-devel_gnu.org
Visibility:
Public.

Description

Issue 5100: Prevent race condition in font export directory making When a font export directory is necessary, LilyPond tested the existence of the directory, and if the directory did not exist, LilyPond made the directory. However, LilyPond raised the error that the directory already exists if another process made the directory between the testing and the making. This commit prevents such race condition. By deleting the existence test, LilyPond always tries to make the directory regardless of existence. Then suppress the error that the directory already exists.

Patch Set 1 #

Total comments: 2

Patch Set 2 : Use if instead of cond #

Unified diffs Side-by-side diffs Delta from patch set Stats (+16 lines, -7 lines) Patch
M scm/framework-ps.scm View 1 1 chunk +16 lines, -7 lines 0 comments Download

Messages

Total messages: 3
dak
https://codereview.appspot.com/319510043/diff/1/scm/framework-ps.scm File scm/framework-ps.scm (right): https://codereview.appspot.com/319510043/diff/1/scm/framework-ps.scm#newcode551 scm/framework-ps.scm:551: (let ((errno (system-error-errno stuff))) This is just (if (= ...
8 months ago (2017-03-19 11:08:08 UTC) #1
trueroad
Use if instead of cond
8 months ago (2017-03-19 15:21:01 UTC) #2
trueroad
8 months ago (2017-03-19 15:22:13 UTC) #3
Thank you for your reviewing.

https://codereview.appspot.com/319510043/diff/1/scm/framework-ps.scm
File scm/framework-ps.scm (right):

https://codereview.appspot.com/319510043/diff/1/scm/framework-ps.scm#newcode551
scm/framework-ps.scm:551: (let ((errno (system-error-errno stuff)))
On 2017/03/19 11:08:07, dak wrote:
> This is just
> (if (= EEXIST (system-error-errno stuff))
>    (ly:debug ...)
>   (throw 'system-error (cdr stuff)))

Done.
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld c59f3c4