ViewVC Help
View File | Revision Log | Show Annotations | Download File | View Changeset | Root Listing
root/zoe/trunk/Zoe.cpp
(Generate patch)

Comparing trunk/Zoe.cpp (file contents):
Revision 38 by douglas, 2004-07-22T22:42:40-07:00 vs.
Revision 39 by douglas, 2004-07-23T17:52:53-07:00

# Line 148 | Line 148 | void Zoe::configure()
148                  << "   password = " << std::string(database.password.GetSize(), '*')
149                  << "\n   db = " << database.db << "\n}\n";
150  
151 +        std::string link(*zoe/"link");
152          xml::NodeSet buddies(*zoe/"buddy");
153  
154          for (xml::NodeSet::Iterator buddy(buddies.Begin()); buddy != buddies.End();
155                  ++buddy)
156          {
157 <                this->buddies.insert(Buddy(**buddy/"login", **buddy/"rss",
158 <                        **buddy/"atom"));
157 >                Buddy buddy_(**buddy/"login", **buddy/"rss", **buddy/"atom",
158 >                        !(**buddy/"link").IsEmpty() ? **buddy/"link" : link);
159 >
160 >                this->buddies.insert(buddy_);
161          }
162  
163          if (debug)
# Line 165 | Line 168 | void Zoe::configure()
168                          buddy != this->buddies.end(); ++buddy)
169                  {
170                          cerr << "   " << *buddy << " = {\n      rss = " << buddy->getRss()
171 <                                << "\n      atom = " << buddy->getAtom() << "\n   }\n";
171 >                                << "\n      atom = " << buddy->getAtom() << "\n      link = "
172 >                                << buddy->getLink() << "\n   }\n";
173                  }
174  
175                  cerr << "}\n";
176          }
177  
178 <        if (!collector && !publisher)
175 <        {
176 <                collector = true;
177 <                publisher = true;
178 <        }
178 >        if (!collector && !publisher) { collector = true; publisher = true; }
179  
180          if (debug) cerr << "collector = " << lexical_cast<ext::String>(collector)
181                  << "\npublisher = " << lexical_cast<ext::String>(publisher)

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines