mirror of
https://github.com/csete/gpredict
synced 2026-08-13 17:39:46 -04:00
Use correct buffer size when creating time strings
Fixes CID 1398137: Out-of-bounds access.
This commit is contained in:
parent
c4f9879cbd
commit
9d727fde46
1 changed files with 2 additions and 2 deletions
|
|
@ -934,7 +934,7 @@ static GooCanvasItemModel *create_time_tick(GtkPolarPlot * pv, gdouble time,
|
|||
gfloat x, gfloat y)
|
||||
{
|
||||
GooCanvasItemModel *item;
|
||||
gchar buff[7];
|
||||
gchar buff[6];
|
||||
GtkAnchorType anchor;
|
||||
GooCanvasItemModel *root;
|
||||
guint32 col;
|
||||
|
|
@ -943,7 +943,7 @@ static GooCanvasItemModel *create_time_tick(GtkPolarPlot * pv, gdouble time,
|
|||
|
||||
col = sat_cfg_get_int(SAT_CFG_INT_POLAR_TRACK_COL);
|
||||
|
||||
daynum_to_str(buff, 8, "%H:%M", time);
|
||||
daynum_to_str(buff, 6, "%H:%M", time);
|
||||
|
||||
if (x > pv->cx)
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue