summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2012-09-28gdbus: Fix crash when getting disconnected from the busJohan Hedberg1-4/+5
When getting disconnected from the bus sometimes (maybe always?) dbus_watch_handle() can cause the "info" context to be free'd meaning that we should not try to access it after the call. The only member we need access to is the connection pointer and as the code already has a ref() call for it it's only natural to solve the issue by adding a local variable not dependent on "info". The backtrace of the crash fixed looks as follows: Invalid read of size 8 at 0x121085: watch_func (mainloop.c:105) by 0x4C72694: g_main_context_dispatch (gmain.c:2539) by 0x4C729C7: g_main_context_iterate.isra.23 (gmain.c:3146) by 0x4C72DC1: g_main_loop_run (gmain.c:3340) by 0x120541: main (main.c:551) Address 0x5bbcd90 is 16 bytes inside a block of size 24 free'd at 0x4A079AE: free (vg_replace_malloc.c:427) by 0x4C7837E: g_free (gmem.c:252) by 0x4F708BF: dbus_watch_set_data (dbus-watch.c:614) by 0x4F70938: _dbus_watch_unref (dbus-watch.c:132) by 0x4F6E9A7: _dbus_transport_handle_watch (dbus-transport.c:884) by 0x4F59AFB: _dbus_connection_handle_watch (dbus-connection.c:1497) by 0x4F70AF9: dbus_watch_handle (dbus-watch.c:683) by 0x121084: watch_func (mainloop.c:103) by 0x4C72694: g_main_context_dispatch (gmain.c:2539) by 0x4C729C7: g_main_context_iterate.isra.23 (gmain.c:3146) by 0x4C72DC1: g_main_loop_run (gmain.c:3340) by 0x120541: main (main.c:551)
2012-09-28wispr: Service does not need to be reference countedPatrik Flykt2-5/+1
2012-09-28wispr: Free wispr portal context struct instead of unreferencing itPatrik Flykt1-40/+9
The structure can now be directly freed, since the reference count is always one. As a result, remove wispr_portal_context_unref() function.
2012-09-28wispr: Remove service usage reset functionPatrik Flykt1-22/+2
Remove reset_service_usage() as it is now obsolete with the refcount always being equal to one.
2012-09-28wispr: Agent calls need not be referencedPatrik Flykt1-29/+2
There is no need to refcount while doing Agent API calls, since outstanding Agent API calls are removed when the service is disconnected. Also remove wispr_portal_context_ref() as it is no longer used.
2012-09-28wispr: Clean up reference countingPatrik Flykt1-22/+9
connman_wispr_portal_context is initialized with refcount set to one. Don't reference it an additional times while doing asynchronous calls if the calls can be cancelled. Unreference the structure when done.
2012-09-28TODO: Add --nobacktrace removal taskPatrik Flykt1-0/+9
2012-09-28log: Disable stack trace from command linePatrik Flykt4-10/+17
Add a '--nobacktrace' command line switch to let the system handle stack traces. The default is to let ConnMan handle them as before
2012-09-28test: Fix PrefixLength setting in set-ipv6-methodTomasz Bursztyka1-1/+4
2012-09-28ipconfig: Fix IPv6.Configuration parsingTomasz Bursztyka1-5/+3
PrefixLength is exposed as a byte in the API, but code was waiting for a string when setting a new value.
2012-09-27unit: Do not append empty AllowedBearers dictionaryDaniel Wagner1-0/+3
An empty AllowedBearers means do not match anything.
2012-09-27session: Apply policy on AllowedBearersDaniel Wagner1-3/+100
2012-09-27session: Update AllowedBearers documentationDaniel Wagner1-1/+10
2012-09-27unit: Support ConnectionType unknownDaniel Wagner1-1/+3
2012-09-27session: Apply policy on ConnnectionTypeDaniel Wagner1-2/+22
2012-09-27session: Enforce correct ConnectionType settingsDaniel Wagner2-5/+16
Up to now an empty or wrong ConnectionType was interpreted as 'any'. If the ConnectionType is either wrong ignore it. If no ConnectionType setting is passed in during creation of the session choose 'any'.
2012-09-27session: Update ConnnectionType documentationDaniel Wagner1-5/+13
2012-09-27session: Support no match in AllowedBearersDaniel Wagner1-24/+25
Up to now an empty AllowedBearers was interpreted as match any. Let's make the match all explicit by expecting '*'. If an empty AllowedBearers is provided, we interpret this as no match. In this case the application will never get an online notifcation.
2012-09-27session_policy: Use bearer free functionDaniel Wagner1-10/+1
2012-09-27session: Use g_slist_free_full to free bearer listDaniel Wagner1-3/+2
2012-09-27session: Add bearer list cleanup functionDaniel Wagner2-13/+11
2012-09-27session: Remove unused functionsDaniel Wagner3-71/+0
Basic types are not used for the configuration anymore.
2012-09-27session: Get config from policy pluginDaniel Wagner1-51/+29
Let's ask the plugin for the default configuration. AllowedBearers and ConnectionType are not yet taken fromt the plugin. Instead the user configuration will be taken.
2012-09-27session_policy: Implement create() and destroy()Daniel Wagner1-0/+63
2012-09-27session: Add callbacks for config creation and distructionDaniel Wagner1-0/+3
Whenever a new session is created, the core will ask the plugin the create the config. This config can then be used by the core to enforce the user settings. The owner ship of this config stays in the plugin. Therefore, the plugin will destroy is later.
2012-09-27session: Allow plugin access to connman_session_allowed_bearers_anyDaniel Wagner2-3/+5
2012-09-27session: Move configuration bits to a public structDaniel Wagner3-66/+55
Instead of passing basic datatypes between the session core and the policy plugin, provide a complex data structure which holds the session configuration.
2012-09-27session: Move bearer_info to session.hDaniel Wagner2-46/+47
Rename bearer_info to connman_session_bearer. Use also 'bearer' as local variable instead of 'info' to avoid confusion with session_info.
2012-09-27session: Use session pointer instead of string idDaniel Wagner3-43/+16
Instead of passing in some string to identify we can use the connman_session pointer. This allows us to keep the way sessions are identfied away from the core, e.g. using the D-Bus owner id or something else.
2012-09-27session: Move struct connman_session to session.hDaniel Wagner2-1/+4
2012-09-27session: Update session when policy plugin is added or removedDaniel Wagner1-0/+47
2012-09-27session: Assign config plugin to sessionDaniel Wagner1-0/+20
Let's pick the first plugin. If needed we can add some more smart code later on.
2012-09-27session: Move get config calls after basic session initializationDaniel Wagner1-5/+6
The config call will need some context later on. Therefore, create and initializate with the owner and add the watch on the ownership before we ask the policy plugin for any configuration.
2012-09-27session: Maintain a sorted policy plugin listDaniel Wagner1-0/+13
2012-09-27session: Remove global configuration pluginDaniel Wagner1-28/+13
Implement support for per session configuration plugin. Obviously, this patch itsel is not complete. The code for assigning a configuration plugin to session->config follows in the next patches.
2012-09-27session: Add plugin priorityDaniel Wagner2-0/+6
Support several session configuration plugins at runtime. Set the default priority to low for the current policy plugin.
2012-09-27session: Move policy plugin code upDaniel Wagner1-92/+92
We don't want to have forwared decleration and the next patches would make this necessary.
2012-09-27session: Rename session_config to session_policyDaniel Wagner3-35/+35
2012-09-27session: No need to free NULL listDaniel Wagner1-4/+1
2012-09-27session: Check D-Bus argumets for Changed methodDaniel Wagner1-0/+7
2012-09-27unit: Update session unit test to API changesDaniel Wagner2-124/+3
2012-09-27session: Remove AvoidHandover implementationDaniel Wagner1-29/+1
2012-09-27session: Remove AvoidHandover documentationDaniel Wagner1-21/+0
The AvoidHandover boolean was there to fine tune the selection algorithm in ConnMan. It was never implemented. Let's get rid for the time beeing. If there is a real need for it we should implemented this setting through the configuration plugin.
2012-09-26manager: Manage properly the pending message for session modeTomasz Bursztyka1-1/+4
2012-09-26README: Mention readline and command line client disable switchPatrik Flykt1-0/+10
2012-09-26build: Add manual pages for connman and config fileJukka Rissanen1-1/+6
2012-09-26resolver: Make sure we do not use already removed timerJukka Rissanen1-0/+1
2012-09-26resolver: Do not touch IPv4 servers in redo caseJukka Rissanen1-0/+13
The name server refresh should be only done for IPv6 nameservers.
2012-09-26dnsproxy: Remove AI_PASSIVE for connected socketJukka Rissanen1-1/+1
The AI_PASSIVE is useless here because the server address is always known.
2012-09-26dnsproxy: Set recipient address when sending msg to DNS serverJukka Rissanen1-2/+12
There has been cases where send() is returning EINVAL even though there is a connected the socket. So use sendto() instead and supply the destination address when sending.