<br><br><div class="gmail_quote">On Thu, Jan 5, 2012 at 12:34 PM, Alon Levy <span dir="ltr"><<a href="mailto:alevy@redhat.com">alevy@redhat.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div class="im">On Thu, Jan 05, 2012 at 12:25:12PM +0100, Marc-André Lureau wrote:<br>
> On Tue, Jan 3, 2012 at 5:52 PM, Alon Levy <<a href="mailto:alevy@redhat.com">alevy@redhat.com</a>> wrote:<br>
><br>
> > + int punctuation = 0;<br>
> ><br>
><br>
> what is this for?<br>
<br>
</div>So we don't accept something like:<br>
spice://hostname?tls-port=1234:1233 INVALID<br>
<br>
so you count the number of "?:&" (punctuation) seen, if you see a ':'<br>
and it isn't the first, fail. This also catches double colon:<br>
spice://hostname:1234:1235 INVALID<br>
<div class="HOEnZb"><div class="h5"><br></div></div></blockquote><div><br></div><div>Yeah, I figured it was used in second patch, could you move it there?</div><div> </div></div><div><br></div>-- <br>Marc-André Lureau<br>