<div dir="ltr">Will do.<div><br></div><div>Ken</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Sun, Oct 5, 2014 at 2:27 PM, Zbigniew Jędrzejewski-Szmek <span dir="ltr"><<a href="mailto:zbyszek@in.waw.pl" target="_blank">zbyszek@in.waw.pl</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">On Fri, Oct 03, 2014 at 04:03:14PM -0700, Ken Sedgwick wrote:<br>
> +const char *subdir = "/test-enabled-root";<br>
> +char root_dir[UNIT_NAME_MAX + 2 + 1] = TEST_DIR;<br>
> +<br>
> +#define confirm_unit_state(unit, expected)                              \<br>
> +        assert_se(unit_file_get_state(UNIT_FILE_SYSTEM, root_dir,<br>
> unit) == expected)<br>
> +<br>
> +static void test_enabled(int argc, char* argv[]) {<br>
> +        Hashmap *h;<br>
> +        UnitFileList *p;<br>
> +        Iterator i;<br>
> +        int r;<br>
> +<br>
> +        strncat(root_dir, subdir, strlen(subdir));<br>
<br>
</span>This is safe, but ungainly. Why not just:<br>
<br>
   const char *root_dir;<br>
<br>
   root_dir = strappenda(TEST_DIR, "/test-enabled-root");<br>
<br>
Test looks useful, but like David wrote, can you please remove the non-essential<br>
bits from the service files?<br>
<br>
Zbyszek<br>
</blockquote></div><br><br clear="all"><div><br></div>-- <br><div dir="ltr"><span style="background-color:rgb(255,255,255);color:rgb(136,136,136);font-family:arial,sans-serif;font-size:13px">Ken Sedgwick</span><br><span style="color:rgb(136,136,136);font-family:arial,sans-serif;font-size:13px;background-color:rgb(255,255,255)">Bonsai Software, Inc.</span><br style="color:rgb(136,136,136);font-family:arial,sans-serif;font-size:13px;background-color:rgb(255,255,255)"><a href="http://www.bonsai.com/ken/" style="color:rgb(17,85,204);font-family:arial,sans-serif;font-size:13px;background-color:rgb(255,255,255)" target="_blank">http://www.bonsai.com/ken/</a><br style="color:rgb(136,136,136);font-family:arial,sans-serif;font-size:13px;background-color:rgb(255,255,255)"><a value="+15106104162" style="color:rgb(17,85,204);font-family:arial,sans-serif;font-size:13px;background-color:rgb(255,255,255)">(510) 269-7334</a><br style="color:rgb(136,136,136);font-family:arial,sans-serif;font-size:13px;background-color:rgb(255,255,255)"><a href="mailto:ken@bonsai.com" style="color:rgb(17,85,204);font-family:arial,sans-serif;font-size:13px;background-color:rgb(255,255,255)" target="_blank">ken@bonsai.com</a><br style="color:rgb(136,136,136);font-family:arial,sans-serif;font-size:13px;background-color:rgb(255,255,255)"><span style="color:rgb(136,136,136);font-family:arial,sans-serif;font-size:13px;background-color:rgb(255,255,255)">Public Key: </span><a href="http://www.bonsai.com/ken/ken.asc" style="color:rgb(17,85,204);font-family:arial,sans-serif;font-size:13px;background-color:rgb(255,255,255)" target="_blank">http://www.bonsai.com/ken/ken.<u></u>asc</a><br style="color:rgb(136,136,136);font-family:arial,sans-serif;font-size:13px;background-color:rgb(255,255,255)"><span style="color:rgb(136,136,136);font-family:arial,sans-serif;font-size:13px;background-color:rgb(255,255,255)">GPG Fingerprint: 851E 3B07 E586 0843 9434  5CC7 4033 3B9B 3F3F 9640</span><br><div><span style="color:rgb(136,136,136);font-family:arial,sans-serif;font-size:13px;background-color:rgb(255,255,255)"><br></span></div></div>
</div>