| commit | 54c874b7b01f3ecbafe5f0485b32e6b5a7c62f38 | [log] [tgz] |
|---|---|---|
| author | David Pursehouse <david.pursehouse@sonymobile.com> | Tue Oct 22 10:18:30 2013 +0900 |
| committer | David Pursehouse <david.pursehouse@sonymobile.com> | Tue Oct 22 10:18:30 2013 +0900 |
| tree | 244791de26108bc8bbe7653246989da21aa37399 | |
| parent | c7ddde32093bd31e94dc23e927bc0e4571351297 [diff] |
Fix lazy initialization of non-volatile static field in GerritLauncher The `myHome` static member of GerritLauncher is lazy initialized in the `getHomeDirectory` method. According to FindBugs: Because the compiler or processor may reorder instructions, threads are not guaranteed to see a completely initialized object, if the method can be called by multiple threads. Fix this by declaring the member as 'volatile'. Change-Id: If2fd90ce83d5b383539aac41dddcacaca1729300