summary refs log tree commit diff
path: root/imbox.c
diff options
context:
space:
mode:
Diffstat (limited to 'imbox.c')
-rw-r--r--imbox.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/imbox.c b/imbox.c
index 850e9b8..bdc8a16 100644
--- a/imbox.c
+++ b/imbox.c
@@ -283,7 +283,7 @@ int main(int argc, char *argv[]) {
 	setlinebuf(imap);
 
 	bool login = false;
-	char *uids = NULL;
+	char *nums = NULL;
 
 	char *line = NULL;
 	size_t cap = 0;
@@ -315,7 +315,7 @@ int main(int argc, char *argv[]) {
 				fprintf(imap, "%s EXAMINE %s\r\n", Atoms[Examine], mailbox);
 			}
 			break; case Examine: {
-				fprintf(imap, "%s UID SEARCH CHARSET UTF-8", Atoms[Search]);
+				fprintf(imap, "%s SEARCH CHARSET UTF-8", Atoms[Search]);
 				if (subject) fprintf(imap, " SUBJECT \"%s\"", subject);
 				if (from) fprintf(imap, " FROM \"%s\"", from);
 				if (to) fprintf(imap, " TO \"%s\"", to);
@@ -323,20 +323,20 @@ int main(int argc, char *argv[]) {
 				fprintf(imap, "\r\n");
 			}
 			break; case Search: {
-				if (!uids) errx(EX_PROTOCOL, "no search response");
-				for (char *ch = uids; *ch; ++ch) {
+				if (!nums) errx(EX_PROTOCOL, "no search response");
+				for (char *ch = nums; *ch; ++ch) {
 					if (*ch == ' ') *ch = ',';
 				}
 				fprintf(
 					imap,
-					"%s UID FETCH %s (BODY[HEADER.FIELDS ("
+					"%s FETCH %s (BODY[HEADER.FIELDS ("
 					"Date From To Cc Subject Message-Id In-Reply-To "
 					"Content-Transfer-Encoding"
 					")] BODY[TEXT])\r\n",
-					Atoms[Fetch], uids
+					Atoms[Fetch], nums
 				);
-				free(uids);
-				uids = NULL;
+				free(nums);
+				nums = NULL;
 			}
 			break; case Fetch: {
 				fprintf(imap, "ayy LOGOUT\r\n");
@@ -349,8 +349,8 @@ int main(int argc, char *argv[]) {
 		switch (resp) {
 			break; case Search: {
 				if (!rest) errx(EX_TEMPFAIL, "no matching messages");
-				uids = strdup(rest);
-				if (!uids) err(EX_OSERR, "strdup");
+				nums = strdup(rest);
+				if (!nums) err(EX_OSERR, "strdup");
 			}
 			break; case Fetch: {
 				char *headers = readLiteral(imap, rest);
/commit/ui-summary.c?id=8fb2f056961e577a039ae185d89ab8e2d2840b9e&follow=1'>Add support for lightweight tagsLars Hjemli There is nothing bad about a tag that has no tag-object, but the old code didn't handle such tags correctly. Fix it. Signed-off-by: Lars Hjemli <hjemli@gmail.com> 2007-02-04Read repo-info from /etc/cgitrcLars Hjemli This makes cgit read all repo-info from the configfile, instead of scanning for possible git-dirs below a common root path. This is primarily done to get better security (separate physical path from logical repo-name). In /etc/cgitrc each repo is registered with the following keys: repo.url repo.name repo.path repo.desc repo.owner Note: *Required keys are repo.url and repo.path, all others are optional *Each occurrence of repo.url starts a new repository registration *Default value for repo.name is taken from repo.url *The value of repo.url cannot contain characters with special meaning for urls (i.e. one of /?%&), while repo.name can contain anything. Example: repo.url=cgit-pub repo.name=cgit/public repo.path=/pub/git/cgit repo.desc=My public cgit repo repo.owner=Lars Hjemli repo.url=cgit-priv repo.name=cgit/private repo.path=/home/larsh/src/cgit/.git repo.desc=My private cgit repo repo.owner=Lars Hjemli Signed-off-by: Lars Hjemli <hjemli@gmail.com> 2007-02-04Do not die if tag has no messageLars Hjemli Signed-off-by: Lars Hjemli <hjemli@gmail.com> 2007-02-03Fix search for non-virtual urlsLars Hjemli When cgit don't use virtual urls, the current repo and page url parameters must be included in the search form as hidden input fields. Signed-off-by: Lars Hjemli <hjemli@gmail.com> 2007-01-28Update README with install/config informationLars Hjemli