Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 45098
b: refs/heads/master
c: 43cdff9
h: refs/heads/master
v: v3
  • Loading branch information
Sebastien Dugué authored and Linus Torvalds committed Dec 30, 2006
1 parent 6fa07d4 commit 87b5c56
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 7 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 7479b1ce5ea41a828002c60739cff37f47b62913
refs/heads/master: 43cdff92ad47e0ca024c8a07d29f9bb6119e759c
11 changes: 5 additions & 6 deletions trunk/drivers/char/ipmi/ipmi_watchdog.c
Original file line number Diff line number Diff line change
Expand Up @@ -216,13 +216,13 @@ static int set_param_str(const char *val, struct kernel_param *kp)
{
action_fn fn = (action_fn) kp->arg;
int rv = 0;
char *dup, *s;
char valcp[16];
char *s;

dup = kstrdup(val, GFP_KERNEL);
if (!dup)
return -ENOMEM;
strncpy(valcp, val, 16);
valcp[15] = '\0';

s = strstrip(dup);
s = strstrip(valcp);

down_read(&register_sem);
rv = fn(s, NULL);
Expand All @@ -235,7 +235,6 @@ static int set_param_str(const char *val, struct kernel_param *kp)

out_unlock:
up_read(&register_sem);
kfree(dup);
return rv;
}

Expand Down

0 comments on commit 87b5c56

Please sign in to comment.