diff options
author | Andrew John Hughes <gnu_andrew@member.fsf.org> | 2008-09-10 00:40:53 +0000 |
---|---|---|
committer | Andrew John Hughes <gnu_andrew@member.fsf.org> | 2008-09-10 00:40:53 +0000 |
commit | 9f3e716b63aae6e7c5b0bb335d73a327192b4967 (patch) | |
tree | 8cb407fe21033083353b5cfc385aca781aceb450 /tools | |
parent | ca05f572c92f614d2cd5fe65775a4d7e23d83de2 (diff) | |
download | classpath-9f3e716b63aae6e7c5b0bb335d73a327192b4967.tar.gz |
Fix synchronization issues spotted by FindBugs.
2008-09-09 Andrew John Hughes <gnu_andrew@member.fsf.org>
* tools/gnu/classpath/tools/getopt/Parser.java:
(setHeader(String)): Make synchronized.
(setFooter(String)): Likewise.
* tools/gnu/classpath/tools/rmic/SourceGiopRmicCompiler.java,
(reset()): Make synchronized.
(name(Class)): Likewise.
Diffstat (limited to 'tools')
-rw-r--r-- | tools/gnu/classpath/tools/getopt/Parser.java | 4 | ||||
-rw-r--r-- | tools/gnu/classpath/tools/rmic/SourceGiopRmicCompiler.java | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/tools/gnu/classpath/tools/getopt/Parser.java b/tools/gnu/classpath/tools/getopt/Parser.java index 5b18ecb37..bb38e82ac 100644 --- a/tools/gnu/classpath/tools/getopt/Parser.java +++ b/tools/gnu/classpath/tools/getopt/Parser.java @@ -197,7 +197,7 @@ public class Parser * * @param headerText the header text */ - public void setHeader(String headerText) + public synchronized void setHeader(String headerText) { this.headerText = headerText; } @@ -207,7 +207,7 @@ public class Parser * * @param footerText the footer text */ - public void setFooter(String footerText) + public synchronized void setFooter(String footerText) { this.footerText = footerText; } diff --git a/tools/gnu/classpath/tools/rmic/SourceGiopRmicCompiler.java b/tools/gnu/classpath/tools/rmic/SourceGiopRmicCompiler.java index 335480840..b7ad7f440 100644 --- a/tools/gnu/classpath/tools/rmic/SourceGiopRmicCompiler.java +++ b/tools/gnu/classpath/tools/rmic/SourceGiopRmicCompiler.java @@ -140,7 +140,7 @@ public class SourceGiopRmicCompiler /** * Clear data, preparing for the next compilation. */ - public void reset() + public synchronized void reset() { packag = name = implName = stubName = null; implementedRemotes.clear(); @@ -329,7 +329,7 @@ public class SourceGiopRmicCompiler * the class to name * @return the name of class as it should appear in java language */ - public String name(Class nameIt) + public synchronized String name(Class nameIt) { if (nameIt.isArray()) { |