All pastes #153611 Raw Edit

Unnamed

public text v1 · immutable
#153611 ·published 2006-08-29 18:50 UTC
rendered paste body
    DBusMessageIter sub;
    dbus_message_iter_open_container(&it, DBUS_TYPE_ARRAY,
        DBUS_TYPE_STRING_AS_STRING, &sub);
    set<string>::const_iterator i;
    for (i = s.begin(); i != s.end(); ++i) {
        const char* c = i->c_str();
        printf("%s\n", i->c_str());
        dbus_message_iter_append_basic(&it, DBUS_TYPE_STRING, &c);
    }
    dbus_message_iter_close_container(&it, &sub);