projects
/
citadel.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
0e27e9a
)
* if we need the first urlpart, we musn't move it just left, but add another one...
author
Wilfried Göesgens
<willi@citadel.org>
Mon, 8 Dec 2008 22:08:25 +0000
(22:08 +0000)
committer
Wilfried Göesgens
<willi@citadel.org>
Mon, 8 Dec 2008 22:08:25 +0000
(22:08 +0000)
webcit/context_loop.c
patch
|
blob
|
history
webcit/downloads.c
patch
|
blob
|
history
webcit/messages.c
patch
|
blob
|
history
webcit/msg_renderers.c
patch
|
blob
|
history
webcit/roomops.c
patch
|
blob
|
history
webcit/webcit.c
patch
|
blob
|
history
webcit/webcit.h
patch
|
blob
|
history
diff --git
a/webcit/context_loop.c
b/webcit/context_loop.c
index b7416f0ac10d475e16a4a8fd807eb239b985fdb8..7af1790c1cbf491564e47fb61071ae1fddf11870 100644
(file)
--- a/
webcit/context_loop.c
+++ b/
webcit/context_loop.c
@@
-48,6
+48,7
@@
void DestroySession(struct wcsession **sessions_to_kill)
DeleteHash(&((*sessions_to_kill)->ServCfg));
FreeStrBuf(&((*sessions_to_kill)->UrlFragment1));
FreeStrBuf(&((*sessions_to_kill)->UrlFragment2));
DeleteHash(&((*sessions_to_kill)->ServCfg));
FreeStrBuf(&((*sessions_to_kill)->UrlFragment1));
FreeStrBuf(&((*sessions_to_kill)->UrlFragment2));
+ FreeStrBuf(&((*sessions_to_kill)->UrlFragment3));
FreeStrBuf(&((*sessions_to_kill)->WBuf));
FreeStrBuf(&((*sessions_to_kill)->HBuf));
FreeStrBuf(&((*sessions_to_kill)->CLineBuf));
FreeStrBuf(&((*sessions_to_kill)->WBuf));
FreeStrBuf(&((*sessions_to_kill)->HBuf));
FreeStrBuf(&((*sessions_to_kill)->CLineBuf));
diff --git
a/webcit/downloads.c
b/webcit/downloads.c
index 23bf5f801391e0b410fbd920e3005b4bae7e1ddd..d980ce1d330b674e33d08f4365a9311e6bf21fe0 100644
(file)
--- a/
webcit/downloads.c
+++ b/
webcit/downloads.c
@@
-391,7
+391,7
@@
void download_file(void)
/* Setting to nonzero forces a MIME type of application/octet-stream */
int force_download = 1;
/* Setting to nonzero forces a MIME type of application/octet-stream */
int force_download = 1;
- safestrncpy(buf, ChrPtr(WC->UrlFragment
1
), sizeof buf);
+ safestrncpy(buf, ChrPtr(WC->UrlFragment
2
), sizeof buf);
unescape_input(buf);
serv_printf("OPEN %s", buf);
serv_getln(buf, sizeof buf);
unescape_input(buf);
serv_printf("OPEN %s", buf);
serv_getln(buf, sizeof buf);
diff --git
a/webcit/messages.c
b/webcit/messages.c
index 0713591e736827ba7a311734b7c93262c3d09f2e..2286a04217fca82b8bac9cf887d2fbc0b3dac3b0 100644
(file)
--- a/
webcit/messages.c
+++ b/
webcit/messages.c
@@
-249,7
+249,7
@@
void embed_message(void) {
long msgnum = 0L;
const StrBuf *Tmpl = sbstr("template");
long msgnum = 0L;
const StrBuf *Tmpl = sbstr("template");
- msgnum = StrTol(WC->UrlFragment
1
);
+ msgnum = StrTol(WC->UrlFragment
2
);
if (StrLength(Tmpl) > 0)
read_message(WC->WBuf, SKEY(Tmpl), msgnum, 0, NULL);
else
if (StrLength(Tmpl) > 0)
read_message(WC->WBuf, SKEY(Tmpl), msgnum, 0, NULL);
else
@@
-265,7
+265,7
@@
void embed_message(void) {
void print_message(void) {
long msgnum = 0L;
void print_message(void) {
long msgnum = 0L;
- msgnum = StrTol(WC->UrlFragment
1
);
+ msgnum = StrTol(WC->UrlFragment
2
);
output_headers(0, 0, 0, 0, 0, 0);
hprintf("Content-type: text/html\r\n"
output_headers(0, 0, 0, 0, 0, 0);
hprintf("Content-type: text/html\r\n"
@@
-286,7
+286,7
@@
void print_message(void) {
*/
void mobile_message_view(void) {
long msgnum = 0L;
*/
void mobile_message_view(void) {
long msgnum = 0L;
- msgnum = StrTol(WC->UrlFragment
1
);
+ msgnum = StrTol(WC->UrlFragment
2
);
output_headers(1, 0, 0, 0, 0, 1);
begin_burst();
do_template("msgcontrols", NULL);
output_headers(1, 0, 0, 0, 0, 1);
begin_burst();
do_template("msgcontrols", NULL);
@@
-303,7
+303,7
@@
void display_headers(void) {
long msgnum = 0L;
char buf[1024];
long msgnum = 0L;
char buf[1024];
- msgnum = StrTol(WC->UrlFragment
1
);
+ msgnum = StrTol(WC->UrlFragment
2
);
output_headers(0, 0, 0, 0, 0, 0);
hprintf("Content-type: text/plain\r\n"
output_headers(0, 0, 0, 0, 0, 0);
hprintf("Content-type: text/plain\r\n"
diff --git
a/webcit/msg_renderers.c
b/webcit/msg_renderers.c
index 005288380fe1db905e0835e707f704e524210115..48f32507f012ea84083c4977eb4f9c8dea5fcd05 100644
(file)
--- a/
webcit/msg_renderers.c
+++ b/
webcit/msg_renderers.c
@@
-176,8
+176,7
@@
int summcmp_rdate(const void *s1, const void *s2) {
/*----------------------------------------------------------------------------*/
/*----------------------------------------------------------------------------*/
-
-
+///void examine_subj(message_summary *Msg, StrBuf *HdrLine, StrBuf *FoundCharset)
void examine_nhdr(message_summary *Msg, StrBuf *HdrLine, StrBuf *FoundCharset)
{
void examine_nhdr(message_summary *Msg, StrBuf *HdrLine, StrBuf *FoundCharset)
{
diff --git
a/webcit/roomops.c
b/webcit/roomops.c
index f8a5e4c0efd872c823e49e915717dadeffe7efd2..35a150e3f2cf55f8de4167b0cce8c48c05090838 100644
(file)
--- a/
webcit/roomops.c
+++ b/
webcit/roomops.c
@@
-3201,7
+3201,7
@@
void set_floordiv_expanded(void) {
StrBuf *FloorDiv;
FloorDiv = NewStrBuf();
StrBuf *FloorDiv;
FloorDiv = NewStrBuf();
- StrBufAppendBuf(FloorDiv, WCC->UrlFragment
1
, 0);
+ StrBufAppendBuf(FloorDiv, WCC->UrlFragment
2
, 0);
set_preference("floordiv_expanded", FloorDiv, 1);
WCC->floordiv_expanded = FloorDiv;
}
set_preference("floordiv_expanded", FloorDiv, 1);
WCC->floordiv_expanded = FloorDiv;
}
diff --git
a/webcit/webcit.c
b/webcit/webcit.c
index 1bd1e1ee582eaeb17f58b3614d9d4f847961cb62..d6aa8a0d2d26b8f9b7d152b2de6201a14ab8f50e 100644
(file)
--- a/
webcit/webcit.c
+++ b/
webcit/webcit.c
@@
-927,7
+927,7
@@
void display_vcard_photo_img(void)
const char *contentType;
struct wcsession *WCC = WC;
const char *contentType;
struct wcsession *WCC = WC;
- msgnum = StrTol(WCC->UrlFragment
1
);
+ msgnum = StrTol(WCC->UrlFragment
2
);
vcard = load_mimepart(msgnum,"1");
v = vcard_load(vcard);
vcard = load_mimepart(msgnum,"1");
v = vcard_load(vcard);
@@
-1811,8
+1811,11
@@
void session_loop(HashList *HTTPHeaders, StrBuf *ReqLine, StrBuf *request_method
WCC->UrlFragment1 = NewStrBuf();
if (WCC->UrlFragment2 == NULL)
WCC->UrlFragment2 = NewStrBuf();
WCC->UrlFragment1 = NewStrBuf();
if (WCC->UrlFragment2 == NULL)
WCC->UrlFragment2 = NewStrBuf();
+ if (WCC->UrlFragment3 == NULL)
+ WCC->UrlFragment3 = NewStrBuf();
StrBufPrintf(WCC->UrlFragment1, "%s", index[0]);
StrBufPrintf(WCC->UrlFragment2, "%s", index[1]);
StrBufPrintf(WCC->UrlFragment1, "%s", index[0]);
StrBufPrintf(WCC->UrlFragment2, "%s", index[1]);
+ StrBufPrintf(WCC->UrlFragment3, "%s", index[2]);
}
if ((Handler->Flags & AJAX) != 0)
begin_ajax_response();
}
if ((Handler->Flags & AJAX) != 0)
begin_ajax_response();
@@
-1864,6
+1867,8
@@
void diagnostics(void)
StrEscPuts(WC->UrlFragment1);
wprintf("<br />\n");
StrEscPuts(WC->UrlFragment2);
StrEscPuts(WC->UrlFragment1);
wprintf("<br />\n");
StrEscPuts(WC->UrlFragment2);
+ wprintf("<br />\n");
+ StrEscPuts(WC->UrlFragment3);
wprintf("</PRE><hr />\n");
wprintf("Variables: <br /><PRE>\n");
dump_vars();
wprintf("</PRE><hr />\n");
wprintf("Variables: <br /><PRE>\n");
dump_vars();
@@
-1872,26
+1877,26
@@
void diagnostics(void)
}
void view_mimepart(void) {
}
void view_mimepart(void) {
- mimepart(ChrPtr(WC->UrlFragment
1
),
- ChrPtr(WC->UrlFragment
2
),
+ mimepart(ChrPtr(WC->UrlFragment
2
),
+ ChrPtr(WC->UrlFragment
3
),
0);
}
void download_mimepart(void) {
0);
}
void download_mimepart(void) {
- mimepart(ChrPtr(WC->UrlFragment
1
),
- ChrPtr(WC->UrlFragment
2
),
+ mimepart(ChrPtr(WC->UrlFragment
2
),
+ ChrPtr(WC->UrlFragment
3
),
1);
}
void view_postpart(void) {
1);
}
void view_postpart(void) {
- postpart(WC->UrlFragment
1
,
- WC->UrlFragment
2
,
+ postpart(WC->UrlFragment
2
,
+ WC->UrlFragment
3
,
0);
}
void download_postpart(void) {
0);
}
void download_postpart(void) {
- postpart(WC->UrlFragment
1
,
- WC->UrlFragment
2
,
+ postpart(WC->UrlFragment
2
,
+ WC->UrlFragment
3
,
1);
}
1);
}
@@
-1956,8
+1961,10
@@
void tmplput_url_part(StrBuf *Target, int nArgs, WCTemplateToken *Tokens, void *
if (WCC != NULL) {
if (Tokens->Params[0]->lvalue == 0)
UrlBuf = WCC->UrlFragment1;
if (WCC != NULL) {
if (Tokens->Params[0]->lvalue == 0)
UrlBuf = WCC->UrlFragment1;
- else
+ else
if (Tokens->Params[0]->lvalue == 1)
UrlBuf = WCC->UrlFragment2;
UrlBuf = WCC->UrlFragment2;
+ else
+ UrlBuf = WCC->UrlFragment3;
StrBufAppendTemplate(Target, nArgs, Tokens, Context, ContextType,
UrlBuf, 1);
StrBufAppendTemplate(Target, nArgs, Tokens, Context, ContextType,
UrlBuf, 1);
diff --git
a/webcit/webcit.h
b/webcit/webcit.h
index 371aac8dadc48a3dd1dc616ab11e0f376d84b7c0..a2eb57c92ccf71aef51bb59f02432d89ea28aea2 100644
(file)
--- a/
webcit/webcit.h
+++ b/
webcit/webcit.h
@@
-617,6
+617,7
@@
struct wcsession {
int time_format_cache; /**< which timeformat does our user like? */
StrBuf *UrlFragment1; /**< first urlfragment, if NEED_URL is specified by the handler*/
StrBuf *UrlFragment2; /**< second urlfragment, if NEED_URL is specified by the handler*/
int time_format_cache; /**< which timeformat does our user like? */
StrBuf *UrlFragment1; /**< first urlfragment, if NEED_URL is specified by the handler*/
StrBuf *UrlFragment2; /**< second urlfragment, if NEED_URL is specified by the handler*/
+ StrBuf *UrlFragment3; /**< third urlfragment, if NEED_URL is specified by the handler*/
StrBuf *WBuf; /**< Our output buffer */
StrBuf *HBuf; /**< Our HeaderBuffer */
StrBuf *CLineBuf; /**< linebuffering client stuff */
StrBuf *WBuf; /**< Our output buffer */
StrBuf *HBuf; /**< Our HeaderBuffer */
StrBuf *CLineBuf; /**< linebuffering client stuff */