1.1 --- a/src/share/jaxws_classes/com/sun/tools/internal/ws/processor/util/DirectoryUtil.java Thu Apr 04 19:05:24 2013 -0700 1.2 +++ b/src/share/jaxws_classes/com/sun/tools/internal/ws/processor/util/DirectoryUtil.java Tue Apr 09 14:51:13 2013 +0100 1.3 @@ -1,5 +1,5 @@ 1.4 /* 1.5 - * Copyright (c) 1997, 2010, Oracle and/or its affiliates. All rights reserved. 1.6 + * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved. 1.7 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 1.8 * 1.9 * This code is free software; you can redistribute it and/or modify it 1.10 @@ -96,12 +96,10 @@ 1.11 1.12 } 1.13 1.14 - private static void ensureDirectory(File dir) 1.15 - throws GeneratorException { 1.16 - 1.17 + private static void ensureDirectory(File dir) throws GeneratorException { 1.18 if (!dir.exists()) { 1.19 - dir.mkdirs(); 1.20 - if (!dir.exists()) { 1.21 + boolean created = dir.mkdirs(); 1.22 + if (!created || !dir.exists()) { 1.23 throw new GeneratorException("generator.cannot.create.dir", 1.24 dir.getAbsolutePath()); 1.25 }