@@ -231,7 +231,7 @@ void ps_fetch_time(zval *zv, const MYSQLND_FIELD * const field,
231
231
{
232
232
struct st_mysqlnd_time t ;
233
233
unsigned int length ; /* First byte encodes the length*/
234
- char * to ;
234
+ char * value ;
235
235
DBG_ENTER ("ps_fetch_time" );
236
236
237
237
if ((length = php_mysqlnd_net_field_length (row ))) {
@@ -262,17 +262,17 @@ void ps_fetch_time(zval *zv, const MYSQLND_FIELD * const field,
262
262
QQ : How to make this unicode without copying two times the buffer -
263
263
Unicode equivalent of spprintf?
264
264
*/
265
- length = spprintf (& to , 0 , "%s%02u:%02u:%02u" , (t .neg ? "-" : "" ), t .hour , t .minute , t .second );
265
+ length = spprintf (& value , 0 , "%s%02u:%02u:%02u" , (t .neg ? "-" : "" ), t .hour , t .minute , t .second );
266
266
267
- DBG_INF_FMT ("%s" , to );
267
+ DBG_INF_FMT ("%s" , value );
268
268
#if MYSQLND_UNICODE
269
269
if (!as_unicode ) {
270
270
#endif
271
- ZVAL_STRINGL (zv , to , length , 1 );
272
- efree (to ); /* allocated by spprintf */
271
+ ZVAL_STRINGL (zv , value , length , 1 );
272
+ efree (value ); /* allocated by spprintf */
273
273
#if MYSQLND_UNICODE
274
274
} else {
275
- ZVAL_UTF8_STRINGL (zv , to , length , ZSTR_AUTOFREE );
275
+ ZVAL_UTF8_STRINGL (zv , value , length , ZSTR_AUTOFREE );
276
276
}
277
277
#endif
278
278
DBG_VOID_RETURN ;
@@ -288,7 +288,7 @@ void ps_fetch_date(zval *zv, const MYSQLND_FIELD * const field,
288
288
{
289
289
struct st_mysqlnd_time t = {0 };
290
290
unsigned int length ; /* First byte encodes the length*/
291
- char * to ;
291
+ char * value ;
292
292
DBG_ENTER ("ps_fetch_date" );
293
293
294
294
if ((length = php_mysqlnd_net_field_length (row ))) {
@@ -313,17 +313,17 @@ void ps_fetch_date(zval *zv, const MYSQLND_FIELD * const field,
313
313
QQ : How to make this unicode without copying two times the buffer -
314
314
Unicode equivalent of spprintf?
315
315
*/
316
- length = spprintf (& to , 0 , "%04u-%02u-%02u" , t .year , t .month , t .day );
316
+ length = spprintf (& value , 0 , "%04u-%02u-%02u" , t .year , t .month , t .day );
317
317
318
- DBG_INF_FMT ("%s" , to );
318
+ DBG_INF_FMT ("%s" , value );
319
319
#if MYSQLND_UNICODE
320
320
if (!as_unicode ) {
321
321
#endif
322
- ZVAL_STRINGL (zv , to , length , 1 );
323
- efree (to ); /* allocated by spprintf */
322
+ ZVAL_STRINGL (zv , value , length , 1 );
323
+ efree (value ); /* allocated by spprintf */
324
324
#if MYSQLND_UNICODE
325
325
} else {
326
- ZVAL_UTF8_STRINGL (zv , to , length , ZSTR_AUTOFREE );
326
+ ZVAL_UTF8_STRINGL (zv , value , length , ZSTR_AUTOFREE );
327
327
}
328
328
#endif
329
329
DBG_VOID_RETURN ;
@@ -339,7 +339,7 @@ void ps_fetch_datetime(zval *zv, const MYSQLND_FIELD * const field,
339
339
{
340
340
struct st_mysqlnd_time t ;
341
341
unsigned int length ; /* First byte encodes the length*/
342
- char * to ;
342
+ char * value ;
343
343
DBG_ENTER ("ps_fetch_datetime" );
344
344
345
345
if ((length = php_mysqlnd_net_field_length (row ))) {
@@ -371,15 +371,15 @@ void ps_fetch_datetime(zval *zv, const MYSQLND_FIELD * const field,
371
371
QQ : How to make this unicode without copying two times the buffer -
372
372
Unicode equivalent of spprintf?
373
373
*/
374
- length = spprintf (& to , 0 , "%04u-%02u-%02u %02u:%02u:%02u" ,
374
+ length = spprintf (& value , 0 , "%04u-%02u-%02u %02u:%02u:%02u" ,
375
375
t .year , t .month , t .day , t .hour , t .minute , t .second );
376
376
377
- DBG_INF_FMT ("%s" , to );
377
+ DBG_INF_FMT ("%s" , value );
378
378
#if MYSQLND_UNICODE
379
379
if (!as_unicode ) {
380
380
#endif
381
- ZVAL_STRINGL (zv , to , length , 1 );
382
- efree (to ); /* allocated by spprintf */
381
+ ZVAL_STRINGL (zv , value , length , 1 );
382
+ efree (value ); /* allocated by spprintf */
383
383
#if MYSQLND_UNICODE
384
384
} else {
385
385
ZVAL_UTF8_STRINGL (zv , to , length , ZSTR_AUTOFREE );
0 commit comments