diff options
author | Dan Aloni <da-x@monatomic.org> | 2007-05-17 01:11:16 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-05-17 08:23:05 -0400 |
commit | 71ce92f3fa442069670a52fa6230a6064c4517b3 (patch) | |
tree | 30fec3491b9655040d90c810785ce7e843a90f93 /fs | |
parent | bc88d5d4e18add7283770ead2734b601c50b3e2a (diff) |
make sysctl/kernel/core_pattern and fs/exec.c agree on maximum core filename size
Make sysctl/kernel/core_pattern and fs/exec.c agree on maximum core
filename size and change it to 128, so that extensive patterns such as
'/local/cores/%e-%h-%s-%t-%p.core' won't result in truncated filename
generation.
Signed-off-by: Dan Aloni <da-x@monatomic.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'fs')
-rw-r--r-- | fs/exec.c | 4 |
1 files changed, 1 insertions, 3 deletions
@@ -60,7 +60,7 @@ | |||
60 | #endif | 60 | #endif |
61 | 61 | ||
62 | int core_uses_pid; | 62 | int core_uses_pid; |
63 | char core_pattern[128] = "core"; | 63 | char core_pattern[CORENAME_MAX_SIZE] = "core"; |
64 | int suid_dumpable = 0; | 64 | int suid_dumpable = 0; |
65 | 65 | ||
66 | EXPORT_SYMBOL(suid_dumpable); | 66 | EXPORT_SYMBOL(suid_dumpable); |
@@ -1264,8 +1264,6 @@ int set_binfmt(struct linux_binfmt *new) | |||
1264 | 1264 | ||
1265 | EXPORT_SYMBOL(set_binfmt); | 1265 | EXPORT_SYMBOL(set_binfmt); |
1266 | 1266 | ||
1267 | #define CORENAME_MAX_SIZE 64 | ||
1268 | |||
1269 | /* format_corename will inspect the pattern parameter, and output a | 1267 | /* format_corename will inspect the pattern parameter, and output a |
1270 | * name into corename, which must have space for at least | 1268 | * name into corename, which must have space for at least |
1271 | * CORENAME_MAX_SIZE bytes plus one byte for the zero terminator. | 1269 | * CORENAME_MAX_SIZE bytes plus one byte for the zero terminator. |