projects
/
citadel.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
cc3db1b
)
* When saving a wiki page, set the message subject to the page name. This will make...
author
Art Cancro
<ajc@citadel.org>
Sun, 8 Nov 2009 04:50:42 +0000
(
04:50
+0000)
committer
Art Cancro
<ajc@citadel.org>
Sun, 8 Nov 2009 04:50:42 +0000
(
04:50
+0000)
citadel/modules/wiki/serv_wiki.c
patch
|
blob
|
history
diff --git
a/citadel/modules/wiki/serv_wiki.c
b/citadel/modules/wiki/serv_wiki.c
index c99f7e1b8b504b1fa489ebf579879a829dff86d9..d3d071b4132a255485024289d4625892b0281ee3 100644
(file)
--- a/
citadel/modules/wiki/serv_wiki.c
+++ b/
citadel/modules/wiki/serv_wiki.c
@@
-125,6
+125,12
@@
int wiki_upload_beforesave(struct CtdlMessage *msg) {
/* If there's no message text, obviously this is all b0rken and shouldn't happen at all */
if (msg->cm_fields['M'] == NULL) return(0);
/* If there's no message text, obviously this is all b0rken and shouldn't happen at all */
if (msg->cm_fields['M'] == NULL) return(0);
+ /* Set the message subject identical to the page name */
+ if (msg->cm_fields['U'] != NULL) {
+ free(msg->cm_fields['U']);
+ }
+ msg->cm_fields['U'] = strdup(msg->cm_fields['E']);
+
/* See if we can retrieve the previous version. */
old_msgnum = locate_message_by_euid(msg->cm_fields['E'], &CCC->room);
if (old_msgnum > 0L) {
/* See if we can retrieve the previous version. */
old_msgnum = locate_message_by_euid(msg->cm_fields['E'], &CCC->room);
if (old_msgnum > 0L) {