mirror of
https://github.com/jenkinsci/jenkins.git
synced 2026-11-08 01:26:03 +00:00
[FIXED HUDSON-2715] Field validators in configure screen shouldn't require the admin permission where possible.
git-svn-id: https://hudson.dev.java.net/svn/hudson/trunk/hudson/main@13838 71c3de6d-444a-0410-be80-ed276b4c234a
This commit is contained in:
1 parent
ce015a9c85
commit
fb873cbaf2
23 files changed
+133
-53
No files matched your search
@@ -148,7 +148,7 @@ public class Util {
|
||||
if(!logfile.exists())
|
||||
return "";
|
||||
|
||||
StringBuffer str = new StringBuffer((int)logfile.length());
|
||||
StringBuilder str = new StringBuilder((int)logfile.length());
|
||||
|
||||
BufferedReader r = new BufferedReader(new InputStreamReader(new FileInputStream(logfile),charset));
|
||||
char[] buf = new char[1024];
|
||||
@@ -433,7 +433,7 @@ public class Util {
|
||||
}
|
||||
|
||||
public static String toHexString(byte[] data, int start, int len) {
|
||||
StringBuffer buf = new StringBuffer();
|
||||
StringBuilder buf = new StringBuilder();
|
||||
for( int i=0; i<len; i++ ) {
|
||||
int b = data[start+i]&0xFF;
|
||||
if(b<16) buf.append('0');
|
||||
@@ -548,7 +548,7 @@ public class Util {
|
||||
try {
|
||||
boolean escaped = false;
|
||||
|
||||
StringBuffer out = new StringBuffer(s.length());
|
||||
StringBuilder out = new StringBuilder(s.length());
|
||||
|
||||
ByteArrayOutputStream buf = new ByteArrayOutputStream();
|
||||
OutputStreamWriter w = new OutputStreamWriter(buf,"UTF-8");
|
||||
@@ -581,7 +581,7 @@ public class Util {
|
||||
* Escapes HTML unsafe characters like <, &to the respective character entities.
|
||||
*/
|
||||
public static String escape(String text) {
|
||||
StringBuffer buf = new StringBuffer(text.length()+64);
|
||||
StringBuilder buf = new StringBuilder(text.length()+64);
|
||||
for( int i=0; i<text.length(); i++ ) {
|
||||
char ch = text.charAt(i);
|
||||
if(ch=='\n')
|
||||
@@ -607,7 +607,7 @@ public class Util {
|
||||
}
|
||||
|
||||
public static String xmlEscape(String text) {
|
||||
StringBuffer buf = new StringBuffer(text.length()+64);
|
||||
StringBuilder buf = new StringBuilder(text.length()+64);
|
||||
for( int i=0; i<text.length(); i++ ) {
|
||||
char ch = text.charAt(i);
|
||||
if(ch=='<')
|
||||
|
||||
Reference in new issue
Block a user