On Tue, Feb 24, 2015 at 06:32:31PM +0200, Aaro Koskinen wrote:
> If we have less samples than expected, systemd-bootchart will crash.
>
> Signed-off-by: Aaro Koskinen <[email protected]>
No need for SOB.
> ---
> src/bootchart/svg.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/src/bootchart/svg.c b/src/bootchart/svg.c
> index e111fa9..144177c 100644
> --- a/src/bootchart/svg.c
> +++ b/src/bootchart/svg.c
> @@ -1170,7 +1170,7 @@ static void svg_ps_bars(void) {
>
> ps->sample = ps->sample->next;
> sample_hz = ps->sample;
> - for (ii=0;((ii<(int)arg_hz/2)&&(ps->sample->next));ii++)
> + for (ii=0;((ii<(int)arg_hz/2)&&(sample_hz->next));ii++)
> sample_hz = sample_hz->next;
Applied.
Zbyszek
_______________________________________________
systemd-devel mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/systemd-devel