Fix bad strncmp length
authorDavid Goulet <david.goulet@polymtl.ca>
Thu, 28 Jul 2011 16:13:02 +0000 (12:13 -0400)
committerDavid Goulet <david.goulet@polymtl.ca>
Thu, 28 Jul 2011 16:13:02 +0000 (12:13 -0400)
Signed-off-by: David Goulet <david.goulet@polymtl.ca>
ltt-sessiond/session.c

index 7a7bf3e572eaf500f34df226789af94efd4bf240..3131006f19254072119d41ecccfc3d37f9c1c95c 100644 (file)
@@ -132,7 +132,7 @@ struct ltt_session *find_session_by_name(char *name)
 
        lock_session_list();
        cds_list_for_each_entry(iter, &ltt_session_list.head, list) {
-               if (strncmp(iter->name, name, strlen(name)) == 0) {
+               if (strncmp(iter->name, name, NAME_MAX) == 0) {
                        found = 1;
                        break;
                }
This page took 0.032592 seconds and 4 git commands to generate.