<html><body><div style="font-family:Calibri, Arial, Helvetica, sans-serif; font-size:12.0pt; line-height:1.3; color:#1F497D"><!-- ##### NINE BODY BEGIN ##### -->The key is that they aren't nullptr. As such, the behaviour isn't undefined. <br><br>As it's called with length set to 0, it is fine. <br><br>Vector::data() is the one you would want to use though. <br><div><br></div><div id="signature-x" style="-webkit-user-select:none; font-family:Calibri, Arial, Helvetica, sans-serif; font-size:12.0pt; color:#1F497D" class = "signature_editor">Get Firefox on Android<br></div><!-- ##### NINE BODY END ##### --></div><div class="quoted_output_body"><div id="quoted_header" class="quoted_header_editor" style="clear:both;"><hr style="border:none; height:1px; color:#E1E1E1; background-color:#E1E1E1;"/><div style="border:none; padding:3.0pt 0cm 0cm 0cm"><span style="font-size:11.0pt;font-family:Calibri, Arial, Helvetica, sans-serif"><b>From:</b> Gary Buhrmaster<br><b>Sent:</b> Friday, 11 May 2018 08:05<br><b>To:</b> Development of MythTV<br><b>Subject:</b> Re: [mythtv] regression with 7f00642b<br></span></div></div><br type='attribution'><div id="quoted_body" class="quoted_body_editor"><p dir="ltr">On Fri, May 11, 2018 at 8:04 AM, Jean-Yves Avenard <jyavenard@gmail.com> wrote: <br>
> On 11 May 2018 at 09:53, Jean-Yves Avenard <jyavenard@gmail.com> wrote: <br>
>> reverse that change and pass &gdesc.front() instead <br>
>> <br>
>> (and &pdesc.front()) <br>
> <br>
> actually, &*gdesc.begin() may be better. <br>
<br>
My recollection (of the standard) is that if the <br>
vector is empty, neither begin() nor front() are <br>
defined and/or can be dereferenced.  And these <br>
are cases where the vector is empty. <br>
<br>
But I would certainly defer to someone who <br>
knows the standards better than I. <br>
_______________________________________________ <br>
mythtv-dev mailing list <br>
mythtv-dev@mythtv.org <br>
http://lists.mythtv.org/mailman/listinfo/mythtv-dev <br>
http://wiki.mythtv.org/Mailing_List_etiquette <br>
MythTV Forums: https://forum.mythtv.org <br>
</p>
</div></div></div></body></html>