1.1 --- a/src/os/solaris/vm/os_solaris.cpp Wed Feb 12 11:33:30 2014 -0800 1.2 +++ b/src/os/solaris/vm/os_solaris.cpp Thu Feb 13 11:28:17 2014 -0500 1.3 @@ -1,5 +1,5 @@ 1.4 /* 1.5 - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. 1.6 + * Copyright (c) 1997, 2014, 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 @@ -1788,9 +1788,6 @@ 1.11 ::abort(); // dump core (for debugging) 1.12 } 1.13 1.14 -// unused 1.15 -void os::set_error_file(const char *logfile) {} 1.16 - 1.17 // DLL functions 1.18 1.19 const char* os::dll_file_extension() { return ".so"; } 1.20 @@ -2474,6 +2471,7 @@ 1.21 // determine if this is a legacy image or modules image 1.22 // modules image doesn't have "jre" subdirectory 1.23 len = strlen(buf); 1.24 + assert(len < buflen, "Ran out of buffer space"); 1.25 jrelib_p = buf + len; 1.26 snprintf(jrelib_p, buflen-len, "/jre/lib/%s", cpu_arch); 1.27 if (0 != access(buf, F_OK)) { 1.28 @@ -2492,7 +2490,7 @@ 1.29 } 1.30 } 1.31 1.32 - strcpy(saved_jvm_path, buf); 1.33 + strncpy(saved_jvm_path, buf, MAXPATHLEN); 1.34 } 1.35 1.36