Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FixedFieldPackager pack padding was not being used #323

Closed
wants to merge 1 commit into from

Conversation

mchhil-incomm
Copy link

The pack method was padding the value but the padded value was not being used.

        FixedFieldPackager f1 = new FixedFieldPackager("F1", 20,
                                                              AsciiInterpreter.INSTANCE);

        FSDMsgX               msg = new FSDMsgX("Test1");
        msg.add("F1", f1);

        msg.set("F1", "1234");


        byte[] arr = msg.pack();

        System.out.println(msg.getParserTree(""));
        System.out.println(msg.hexDump(""));

Output . You can see the space padding now. Before you would just see 1234

[Test1]
Field [F1] : Fixed [20] :                 1234

0000  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20                  
0010  31 32 33 34                                       1234



The pack method was padding the value but the padded value was not being used.
@mchhil-incomm mchhil-incomm closed this by deleting the head repository Jan 23, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant