<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <meta content="text/html; charset=ISO-8859-1"
      http-equiv="Content-Type">
    <title></title>
  </head>
  <body bgcolor="#ffffff" text="#000000">
    On 2011年11月01日 15:12, Philipp Hahn wrote:
    <blockquote cite="mid:201111010812.57818.hahn@univention.de"
      type="cite">
      <pre wrap="">Now you have it the other way around, that any prefix matches:
 "virsh -c hai" will match "hail".
Why not simply use STREQ instead of STREQLEN?

Sincerely
Philipp
</pre>
    </blockquote>
    <font face="Helvetica, Arial, sans-serif">ooooooops..You're
      right.But here I think we can't use STREQ because in config file
      the compared string is "hail=qemu:///system"</font><span
      class="Apple-style-span" style="color: rgb(0, 0, 0); font-family:
      'AR PL UKai CN'; font-style: normal; font-variant: normal;
      font-weight: normal; letter-spacing: normal; line-height: normal;
      orphans: 2; text-indent: 0px; text-transform: none; white-space:
      normal; widows: 2; word-spacing: 0px; background-color: rgb(255,
      255, 255); font-size: medium;"><font face="Helvetica, Arial,
        sans-serif"> not just "hail" with  NULL followed<br>
        <br>
        is this one right?<br>
        <br>
            size_t alias_len;<br>
            alias_len = strlen(alias);<br>
        <br>
            if (STREQLEN(entry->str, alias, alias_len) &&
        alias_len == </font></span><span class="Apple-style-span"
      style="color: rgb(0, 0, 0); font-family: 'AR PL UKai CN';
      font-style: normal; font-variant: normal; font-weight: normal;
      letter-spacing: normal; line-height: normal; orphans: 2;
      text-indent: 0px; text-transform: none; white-space: normal;
      widows: 2; word-spacing: 0px; background-color: rgb(255, 255,
      255); font-size: medium;"><font face="Helvetica, Arial,
        sans-serif">(offset-entry->str</font></span><span
      class="Apple-style-span" style="color: rgb(0, 0, 0); font-family:
      'AR PL UKai CN'; font-style: normal; font-variant: normal;
      font-weight: normal; letter-spacing: normal; line-height: normal;
      orphans: 2; text-indent: 0px; text-transform: none; white-space:
      normal; widows: 2; word-spacing: 0px; background-color: rgb(255,
      255, 255); font-size: medium;"><font face="Helvetica, Arial,
        sans-serif">))<br>
      </font></span><br>
  </body>
</html>