Skip to content

Commit f3da64d

Browse files
Fabian Fredericktorvalds
authored andcommitted
kernel/profile.c: use static const char instead of static char
schedstr, sleepstr and kvmstr are only used in strcmp & strlen Signed-off-by: Fabian Frederick <fabf@skynet.be> Cc: Paul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
1 parent aba871f commit f3da64d

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

‎kernel/profile.c‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -52,9 +52,9 @@ static DEFINE_MUTEX(profile_flip_mutex);
5252

5353
int profile_setup(char *str)
5454
{
55-
static char schedstr[] = "schedule";
56-
static char sleepstr[] = "sleep";
57-
static char kvmstr[] = "kvm";
55+
static const char schedstr[] = "schedule";
56+
static const char sleepstr[] = "sleep";
57+
static const char kvmstr[] = "kvm";
5858
int par;
5959

6060
if (!strncmp(str, sleepstr, strlen(sleepstr))) {

0 commit comments

Comments
 (0)