253254255256257258259260261262263
//Write up to 32 products; stop if we see a null for(int product : icon.products) { if(product == 0) break; headerStream.writeDWord(product); } headerStream.writeDWord(0); }
255256257258259260261262263264265
for(int product : icon.products) { if(product == 0) break; headerStream.writeDWord(product); } headerStream.writeDWord(0); } byte[] header = baos.toByteArray(); os.writeDWord(header.length);