From bbb239d566dee223636fd1029a1985be4447f182 Mon Sep 17 00:00:00 2001 From: David McKnight Date: Mon, 5 Jun 2006 19:57:58 +0000 Subject: [PATCH] null pointer check for src and host encodings --- .../eclipse/rse/services/dstore/files/DStoreFileService.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/rse/plugins/org.eclipse.rse.services.dstore/src/org/eclipse/rse/services/dstore/files/DStoreFileService.java b/rse/plugins/org.eclipse.rse.services.dstore/src/org/eclipse/rse/services/dstore/files/DStoreFileService.java index 289736544f7..43ce0fcf512 100644 --- a/rse/plugins/org.eclipse.rse.services.dstore/src/org/eclipse/rse/services/dstore/files/DStoreFileService.java +++ b/rse/plugins/org.eclipse.rse.services.dstore/src/org/eclipse/rse/services/dstore/files/DStoreFileService.java @@ -224,7 +224,7 @@ public class DStoreFileService extends AbstractDStoreService implements IFileSer String byteStreamHandlerId = getByteStreamHandlerId(); String remotePath = remoteParent + getSeparator(remoteParent) + remoteFile; - if (!isBinary) + if (!isBinary && hostEncoding != null) { String tempStr = new String(buffer, 0, bytesRead); @@ -393,7 +393,7 @@ public class DStoreFileService extends AbstractDStoreService implements IFileSer String byteStreamHandlerId = getByteStreamHandlerId(); String remotePath = remoteParent + getSeparator(remoteParent) + remoteFile; - if (!isBinary) + if (!isBinary && srcEncoding != null && hostEncoding != null) { String tempStr = new String(buffer, 0, bytesRead, srcEncoding);