pidgin: 55ded7e8: A while ago I noticed that we don't have...
markdoliner at pidgin.im
markdoliner at pidgin.im
Sat Aug 20 20:55:33 EDT 2011
----------------------------------------------------------------------
Revision: 55ded7e8bbd30adb45c2d04af599ded6383526cc
Parent: ab48119a2d860ed769578a68340e8a8464ebe0ea
Author: markdoliner at pidgin.im
Date: 08/20/11 20:54:23
Branch: im.pidgin.pidgin
URL: http://d.pidgin.im/viewmtn/revision/info/55ded7e8bbd30adb45c2d04af599ded6383526cc
Changelog:
A while ago I noticed that we don't have enforce a max on the
number of processes that we fork to do DNS SRV or TXT lookups.
This is pretty minor and I don't care enough to fix it, but it
seems like a good idea to mention it in the code.
Changes against parent ab48119a2d860ed769578a68340e8a8464ebe0ea
patched libpurple/dnssrv.c
-------------- next part --------------
============================================================
--- libpurple/dnssrv.c 37665b78585bc794151ac68498d4fee94f49906e
+++ libpurple/dnssrv.c 01fb6d6cae9c7671c89b1df6a3598159342ba0f9
@@ -798,6 +798,12 @@ purple_srv_resolve_account(PurpleAccount
return NULL;
}
+ /*
+ * TODO: We should put a cap on the number of forked processes that we
+ * allow at any given time. If we get too many requests they
+ * should be put into a queue and handled later. (This is what
+ * we do for A record lookups.)
+ */
pid = fork();
if (pid == -1) {
purple_debug_error("dnssrv", "Could not create process!\n");
@@ -929,6 +935,12 @@ PurpleSrvTxtQueryData *purple_txt_resolv
return NULL;
}
+ /*
+ * TODO: We should put a cap on the number of forked processes that we
+ * allow at any given time. If we get too many requests they
+ * should be put into a queue and handled later. (This is what
+ * we do for A record lookups.)
+ */
pid = fork();
if (pid == -1) {
purple_debug_error("dnssrv", "Could not create process!\n");
More information about the Commits
mailing list