comparison src/queue.c @ 348:a7a387253b2f

Argument of read_queue() was unused, thus removed
author markus schnalke <meillo@marmaro.de>
date Thu, 14 Jul 2011 11:31:52 +0200
parents 5f559921391a
children b45dc53f2829
comparison
equal deleted inserted replaced
347:53cf6be5843a 348:a7a387253b2f
40 } 40 }
41 } 41 }
42 } 42 }
43 43
44 GList* 44 GList*
45 read_queue(gboolean do_readdata) 45 read_queue(void)
46 { 46 {
47 GList *msg_list = NULL; 47 GList *msg_list = NULL;
48 glob_t gl; 48 glob_t gl;
49 gchar *pattern; 49 gchar *pattern;
50 int i, *idx_arr; 50 int i, *idx_arr;
74 /* uid length = 6 chars + '-' + 3 chars + '-' + 2 = 13 chars */ 74 /* uid length = 6 chars + '-' + 3 chars + '-' + 2 = 13 chars */
75 uid = g_strndup(&(gl.gl_pathv[idx_arr[i]][strlen(conf.spool_dir) + 7]), 13); 75 uid = g_strndup(&(gl.gl_pathv[idx_arr[i]][strlen(conf.spool_dir) + 7]), 13);
76 76
77 DEBUG(5) debugf("uid: %s\n", uid); 77 DEBUG(5) debugf("uid: %s\n", uid);
78 78
79 msg_list = g_list_append(msg_list, msg_spool_read(uid, do_readdata)); 79 msg_list = g_list_append(msg_list, msg_spool_read(uid, FALSE));
80 80
81 DEBUG(5) debugf("after read spool file for %s\n", uid); 81 DEBUG(5) debugf("after read spool file for %s\n", uid);
82 82
83 g_free(uid); 83 g_free(uid);
84 } 84 }
90 { 90 {
91 GList *msg_list; 91 GList *msg_list;
92 gboolean ok = TRUE; 92 gboolean ok = TRUE;
93 93
94 logwrite(LOG_NOTICE, "Starting queue run.\n"); 94 logwrite(LOG_NOTICE, "Starting queue run.\n");
95 msg_list = read_queue(FALSE); 95 msg_list = read_queue();
96 if (msg_list) { 96 if (msg_list) {
97 ok = deliver_msg_list(msg_list, DLVR_ALL); 97 ok = deliver_msg_list(msg_list, DLVR_ALL);
98 DEBUG(5) debugf(" deliver_msg_list() returned: %d\n", ok); 98 DEBUG(5) debugf(" deliver_msg_list() returned: %d\n", ok);
99 destroy_msg_list(msg_list); 99 destroy_msg_list(msg_list);
100 } 100 }
108 { 108 {
109 GList *msg_list; 109 GList *msg_list;
110 gboolean ok = TRUE; 110 gboolean ok = TRUE;
111 111
112 logwrite(LOG_NOTICE, "Starting online queue run.\n"); 112 logwrite(LOG_NOTICE, "Starting online queue run.\n");
113 msg_list = read_queue(FALSE); 113 msg_list = read_queue();
114 if (msg_list) { 114 if (msg_list) {
115 ok = deliver_msg_list(msg_list, DLVR_ONLINE); 115 ok = deliver_msg_list(msg_list, DLVR_ONLINE);
116 DEBUG(5) debugf(" deliver_msg_list() returned: %d\n", ok); 116 DEBUG(5) debugf(" deliver_msg_list() returned: %d\n", ok);
117 destroy_msg_list(msg_list); 117 destroy_msg_list(msg_list);
118 } 118 }
138 queue_list() 138 queue_list()
139 { 139 {
140 GList *msg_list; 140 GList *msg_list;
141 GList *msg_node; 141 GList *msg_node;
142 142
143 msg_list = read_queue(FALSE); 143 msg_list = read_queue();
144 144
145 if (msg_list == NULL) { 145 if (msg_list == NULL) {
146 printf("mail queue is empty.\n"); 146 printf("mail queue is empty.\n");
147 return; 147 return;
148 } 148 }