Changeset c3326b98e5caf983652a677980bcf77433519e5b
- Timestamp:
- 03/05/08 03:22:01
(5 years ago)
- Author:
- Theo Schlossnagle <jesus@omniti.com>
- git-committer:
- Theo Schlossnagle <jesus@omniti.com> 1204687321 +0000
- git-parent:
[d2e12b284f29fd7104b23c22bf78a332d9591400]
- git-author:
- Theo Schlossnagle <jesus@omniti.com> 1204687321 +0000
- Message:
=> isn't really nice in XML. So, specify the subscriber (if you want) in parenthesis. /path/to/file(subscriber)
-
Files:
-
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
| r0424292 |
rc3326b9 |
|
| 73 | 73 | if(!ls->path) return -1; |
|---|
| 74 | 74 | strlcpy(path, ls->path, sizeof(path)); |
|---|
| 75 | | sub = strstr(path, "=>"); |
|---|
| | 75 | sub = strchr(path, '('); |
|---|
| 76 | 76 | if(sub) { |
|---|
| 77 | | *sub = '\0'; |
|---|
| 78 | | sub += 2; |
|---|
| 79 | | } |
|---|
| 80 | | log = jlog_new(ls->path); |
|---|
| | 77 | char *esub = strchr(sub, ')'); |
|---|
| | 78 | if(esub) { |
|---|
| | 79 | *esub = '\0'; |
|---|
| | 80 | *sub = '\0'; |
|---|
| | 81 | sub += 1; |
|---|
| | 82 | } |
|---|
| | 83 | } |
|---|
| | 84 | log = jlog_new(path); |
|---|
| 81 | 85 | if(!log) return -1; |
|---|
| 82 | 86 | /* Open the writer. */ |
|---|
| … | … | |
| 86 | 90 | /* path: close, new, init, close, new, writer, add subscriber */ |
|---|
| 87 | 91 | jlog_ctx_close(log); |
|---|
| 88 | | log = jlog_new(ls->path); |
|---|
| | 92 | log = jlog_new(path); |
|---|
| 89 | 93 | if(jlog_ctx_init(log)) { |
|---|
| 90 | 94 | noitL(noit_error, "Cannot init jlog writer: %s\n", |
|---|
| … | … | |
| 95 | 99 | /* After it is initialized, we can try to reopen it as a writer. */ |
|---|
| 96 | 100 | jlog_ctx_close(log); |
|---|
| 97 | | log = jlog_new(ls->path); |
|---|
| | 101 | log = jlog_new(path); |
|---|
| 98 | 102 | if(jlog_ctx_open_writer(log)) { |
|---|
| 99 | 103 | noitL(noit_error, "Cannot open jlog writer: %s\n", |
|---|