Can you find reasonable examples that still break this and you can't see a way to patch it?
In[1]:= f[x_] := x Exp[-3 x];
p1 = Plot[f[x], {x, 0, 1}];
v = x /. {ToRules[Reduce[D[f[x], x] == 0, x]], ToRules[Reduce[D[f[x], {x, 2}] == 0, x]]};
If[VectorQ[v], p2 = Graphics[{{PointSize[Large], Map[Point[{#, f[#]}] &, v]}}]; Show[p1, p2], Show[p1]]
Out[4]= ...PlotSnipped...
In[5]:= f[x_] := (x - 3) (x - 2) (x - 1);
p1 = Plot[f[x], {x, 0, 4}];
v = x /. {ToRules[Reduce[D[f[x], x] == 0, x]], ToRules[Reduce[D[f[x], {x, 2}] == 0, x]]};
If[VectorQ[v], p2 = Graphics[{{PointSize[Large], Map[Point[{#, f[#]}] &, v]}}]; Show[p1, p2], Show[p1]]
Out[8]= ...PlotSnipped...
In[9]:= f[x_] := Exp[x];
p1 = Plot[f[x], {x, 0, 1}];
v = x /. {ToRules[Reduce[D[f[x], x] == 0, x]], ToRules[Reduce[D[f[x], {x, 2}] == 0, x]]};
If[VectorQ[v], p2 = Graphics[{{PointSize[Large], Map[Point[{#, f[#]}] &, v]}}]; Show[p1, p2], Show[p1]]
Out[12]= ...PlotSnipped...
If everything seems to work then can you package it into your function without it somehow breaking?