{"push_id":732366378,"size":3,"distinct_size":3,"ref":"refs/heads/master","head":"9c5b0b7d0e53f72eef8bbf99c9972869a7e6ea0a","before":"819e94cacaf5d7480ca3e9310d63b86402c7c9cb","commits":[{"sha":"2269b32a86f58830eee964a3a34e80668b589d88","author":{"email":"dbd41f80ed6e4c2f4ecbb07e9be5072393a48af9@gmail.com","name":"Benoit Vaugon"},"message":"Fix must_quote call convention to avoid memory corruption when excel_tricks is enabled for output.","distinct":true,"url":"https://api.github.com/repos/Chris00/ocaml-csv/commits/2269b32a86f58830eee964a3a34e80668b589d88"},{"sha":"c602970254def69c04b26eb3fb7f705a67016c6e","author":{"email":"31b857c84ef8b5a36e0408d32d21a2c72c6b4dca@umons.ac.be","name":"Christophe Troestler"},"message":"Add new test about writing CSV files","distinct":true,"url":"https://api.github.com/repos/Chris00/ocaml-csv/commits/c602970254def69c04b26eb3fb7f705a67016c6e"},{"sha":"9c5b0b7d0e53f72eef8bbf99c9972869a7e6ea0a","author":{"email":"31b857c84ef8b5a36e0408d32d21a2c72c6b4dca@umons.ac.be","name":"Christophe Troestler"},"message":"Fix must_quote call convention to avoid memory corruption\n\nThe given patch fixes a bug that implied memory corruptions in some\ncases. The bug is observable on the following code:\n\nCsv.output_all (Csv.to_channel ~excel_tricks:true stdout) [ [ \"01234567\" ] ]\n\nIn fact, it appears when excel_tricks is true and when a field starts\nwith '0', do not contains any occurrence of '\\n', '\\r' or the\nseparator, and have a length of the form (8 * n - 1). In this case,\nthe function must_quote returns -1, and the buffer s allocated on\ncsv.ml line 800 is too small by 1 to store all the characters. The\nlast Byte.unsafe_set then corrupts the size tag of the string s (when\nString.length n mod 8 = 7) or looses the last char in the 0-padding of\nthe string (when String.length n mod 8 < 7). This memory corruption\nimplies funny bugs when the string s is used later.","distinct":true,"url":"https://api.github.com/repos/Chris00/ocaml-csv/commits/9c5b0b7d0e53f72eef8bbf99c9972869a7e6ea0a"}]}