Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- diff --git a/ext/tiny_tds/result.c b/ext/tiny_tds/result.c
- index 7d9f0fa..91f951b 100644
- --- a/ext/tiny_tds/result.c
- +++ b/ext/tiny_tds/result.c
- @@ -157,8 +157,12 @@ static VALUE rb_tinytds_result_fetch_row(VALUE self, ID timezone, int symbolize_
- val = ENCODED_STR_NEW2(converted_unique);
- break;
- }
- - case SYBDATETIME4:
- - dbconvert(rwrap->client, coltype, data, data_len, SYBDATETIME, data, data_len);
- + case SYBDATETIME4: {
- + DBDATETIME new_data;
- + dbconvert(rwrap->client, coltype, data, data_len, SYBDATETIME, &new_data, sizeof(new_data));
- + data = &new_data;
- + data_len = sizeof(new_data);
- + }
- case SYBDATETIME: {
- DBDATEREC date_rec;
- dbdatecrack(rwrap->client, &date_rec, (DBDATETIME *)data);
Add Comment
Please, Sign In to add comment