zhanglistar commented on issue #7092:
URL: 
https://github.com/apache/incubator-gluten/issues/7092#issuecomment-2327709121

   Here is the smallest code to reproduce the problem:
   java code used by Apache Spark:
   ```
   cat Base64DecodeToFile.java
   import java.util.Base64;
   import java.io.FileOutputStream;
   import java.io.IOException;
   
   public class Base64DecodeToFile {
       public static void main(String[] args) {
           String encodedString = 
"AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA¬AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAyAAAAAAAEAAAAAAAAAAggAAAAAAAAAAQAsCQAAgMAAAJECQBUUEQBUAEFAEBMEAEEYRwQFAEFAEAARAACCAEQFEAVRwCAgAAqIAgAAAAALgAQIA7AIAAAABcBNCAQQYjAMAAACAgBptQxGSDAxcACBJBBQQhC5GnCBOVAVJAeQ==";
           byte[] decodedBytes = Base64.getMimeDecoder().decode(encodedString);
   
           String filePath = "output.txt";
   
           try (FileOutputStream outputStream = new FileOutputStream(filePath)) 
{
               outputStream.write(decodedBytes);
               System.out.println("SUC: " + filePath);
           } catch (IOException e) {
               System.out.println("FAIL");
               e.printStackTrace();
           }
       }
   }
   ```
   Gluten code use https://github.com/aklomp/base64.git, if we do not ignore 
invalid character, we got error as in Clikchouse:
   <img width="333" alt="image" 
src="https://github.com/user-attachments/assets/a686a72d-abde-4def-93f9-519482ec4ad2";>
   
   But if we ignore invalid character as Apache Spark, we get the same output:
   <img width="450" alt="image" 
src="https://github.com/user-attachments/assets/ab4c4eaa-a880-4865-b0e6-7686b2d4b11a";>
    


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to