Changeset c08c70a for logging.c


Ignore:
Timestamp:
Aug 15, 2009, 7:08:19 PM (12 years ago)
Author:
Anders Kaseorg <andersk@mit.edu>
Branches:
master, release-1.4, release-1.5, release-1.6, release-1.7, release-1.8, release-1.9
Children:
1fdab04
Parents:
25fb825
git-author:
Anders Kaseorg <andersk@mit.edu> (08/04/09 00:44:38)
git-committer:
Anders Kaseorg <andersk@mit.edu> (08/15/09 19:08:19)
Message:
Add const qualifiers for owl_message *.

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
File:
1 edited

Legend:

Unmodified
Added
Removed
  • logging.c

    re19eb97 rc08c70a  
    99 * functions in this file as necessary.
    1010 */
    11 void owl_log_message(owl_message *m) {
     11void owl_log_message(const owl_message *m) {
    1212  owl_function_debugmsg("owl_log_message: entering");
    1313
     
    3737
    3838/* Return 1 if we should log the given message, otherwise return 0 */
    39 int owl_log_shouldlog_message(owl_message *m) {
     39int owl_log_shouldlog_message(const owl_message *m) {
    4040  owl_filter *f;
    4141
     
    7070}
    7171
    72 void owl_log_zephyr(owl_message *m, FILE *file) {
     72void owl_log_zephyr(const owl_message *m, FILE *file) {
    7373    char *tmp;
    7474    tmp=short_zuser(owl_message_get_sender(m));
     
    8282}
    8383
    84 void owl_log_aim(owl_message *m, FILE *file) {
     84void owl_log_aim(const owl_message *m, FILE *file) {
    8585    fprintf(file, "From: <%s> To: <%s>\n", owl_message_get_sender(m), owl_message_get_recipient(m));
    8686    fprintf(file, "Time: %s\n\n", owl_message_get_timestr(m));
     
    9393}
    9494
    95 void owl_log_jabber(owl_message *m, FILE *file) {
     95void owl_log_jabber(const owl_message *m, FILE *file) {
    9696    fprintf(file, "From: <%s> To: <%s>\n",owl_message_get_sender(m), owl_message_get_recipient(m));
    9797    fprintf(file, "Time: %s\n\n", owl_message_get_timestr(m));
     
    9999}
    100100
    101 void owl_log_generic(owl_message *m, FILE *file) {
     101void owl_log_generic(const owl_message *m, FILE *file) {
    102102    fprintf(file, "From: <%s> To: <%s>\n", owl_message_get_sender(m), owl_message_get_recipient(m));
    103103    fprintf(file, "Time: %s\n\n", owl_message_get_timestr(m));
     
    105105}
    106106
    107 void owl_log_append(owl_message *m, const char *filename) {
     107void owl_log_append(const owl_message *m, const char *filename) {
    108108    FILE *file;
    109109    file=fopen(filename, "a");
     
    124124}
    125125
    126 void owl_log_outgoing(owl_message *m)
     126void owl_log_outgoing(const owl_message *m)
    127127{
    128128  char filename[MAXPATHLEN], *logpath;
     
    227227}
    228228
    229 void owl_log_incoming(owl_message *m)
     229void owl_log_incoming(const owl_message *m)
    230230{
    231231  char filename[MAXPATHLEN], allfilename[MAXPATHLEN], *logpath;
Note: See TracChangeset for help on using the changeset viewer.