]> code.citadel.org Git - citadel.git/blobdiff - webcit/downloads.c
Merge branch 'master' of ssh://git.citadel.org/appl/gitroot/citadel
[citadel.git] / webcit / downloads.c
index eb01d64d051404a6ce62308717ecd0496fa002e6..f7f9c9dc52d390bea015b6fdee455b44ff3267c9 100644 (file)
@@ -3,17 +3,11 @@
  *
  * This program is open source software.  You can redistribute it and/or
  * modify it under the terms of the GNU General Public License, version 3.
- * 
- * 
  *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  * GNU General Public License for more details.
- *
- * 
- * 
- * 
  */
 
 #include "webcit.h"
@@ -44,22 +38,22 @@ void FreeFiles(void *vFile)
 /* -------------------------------------------------------------------------------- */
 void tmplput_FILE_NAME(StrBuf *Target, WCTemplputParams *TP)
 {
-       FileListStruct *F = (FileListStruct*) CTX;
+       FileListStruct *F = (FileListStruct*) CTX(CTX_FILELIST);
        StrBufAppendTemplate(Target, TP, F->Filename, 0);
 }
 void tmplput_FILE_SIZE(StrBuf *Target, WCTemplputParams *TP)
 {
-       FileListStruct *F = (FileListStruct*) CTX;
+       FileListStruct *F = (FileListStruct*) CTX(CTX_FILELIST);
        StrBufAppendPrintf(Target, "%ld", F->FileSize);
 }
 void tmplput_FILEMIMETYPE(StrBuf *Target, WCTemplputParams *TP)
 {
-       FileListStruct *F = (FileListStruct*) CTX;
+       FileListStruct *F = (FileListStruct*) CTX(CTX_FILELIST);
        StrBufAppendTemplate(Target, TP, F->MimeType, 0);
 }
 void tmplput_FILE_COMMENT(StrBuf *Target, WCTemplputParams *TP)
 {
-       FileListStruct *F = (FileListStruct*) CTX;
+       FileListStruct *F = (FileListStruct*) CTX(CTX_FILELIST);
        StrBufAppendTemplate(Target, TP, F->Comment, 0);
 }
 
@@ -67,7 +61,7 @@ void tmplput_FILE_COMMENT(StrBuf *Target, WCTemplputParams *TP)
 
 int Conditional_FILE_ISPIC(StrBuf *Target, WCTemplputParams *TP)
 {
-       FileListStruct *F = (FileListStruct*) CTX;
+       FileListStruct *F = (FileListStruct*) CTX(CTX_FILELIST);
        return F->IsPic;
 }