- 19 Apr, 2022 2 commits
-
-
Lubomir Rintel authored
Fixes this error: checking whether more special flags are required for pthreads... no checking for PTHREAD_PRIO_INHERIT... yes ./configure: line 30294: ,as_fn_error: command not found checking for a Python interpreter with version >= 3... python checking for python... /usr/bin/python
-
Thomas Haller authored
-
- 15 Apr, 2022 25 commits
-
-
Thomas Haller authored
The $URL might already contain a ".git" suffix. Then $FULLNAME would end up having two ".git" extensions. Fix that.
-
Thomas Haller authored
It doesn't work anymore: $ git clone git://github.com/thom311/libnl.git Cloning into 'libnl'... fatal: remote error: The unauthenticated git protocol on port 9418 is no longer supported. Please see https://github.blog/2021-09-01-improving-git-protocol-security-github/ for more information.
-
-
Thomas Haller authored
The goal would be to ensure that a device cannot move to activated, while a DNS update is still pending. This does not really work for most cases. That is, because NMDevice does not directly push DNS updates to NMDnsManager, instead, NMPolicy is watching all device changes, and doing it. But when NMPolicy decides to to that, may not be the right moment. We really should let NMDevice (or better, NML3Cfg) directly talk to NMDnsManager. Why not? They have all the information when new DNS configuration is available. The only thing that NMPolicy does on top of that, is determining which device has the best default route. NMPolicy could continue to do that (or maybe NMDnsManager could), but the update needs to be directly triggered by NMDevice/NML3Cfg.
-
Thomas Haller authored
While we have DNS updates pending, we cannot reach startup complete.
-
Thomas Haller authored
nm_dns_manager_get() is already a singleton. So users usually can just get it whenever they need -- except during shutdown after the singleton was destroyed. This is usually fine, because users really should not try to get it late during shutdown. However, if you subscribe a signal handler on the singleton, then you will also eventually want to unsubscribe it. While the moment when you subscribe it is clearly not during late-shutdown, it's not clear how to ensure that the signal listener gets destroyed before the DNS manager singleton. So usually, whenever you are going to subscribe a signal, you need to make sure that the target object stays alive long enough. Which may mean to keep a reference to it. Next, we will have NMDevice subscribe to the singleton. With above said, that would mean that potentially every NMDevice needs to keep a reference to the NMDnsManager. That is not best. Also, later NMManager will face the same problem, because it will also subscribe to NMDnsManager. So, instead let NMManager own a reference to the NMDnsManager. This ensures the lifetimes are properly guarded (NMDevice also references NMManager already). Also, access nm_dns_manager_get() lazy on first use, to only initialize it when needed the first time (which might be quite late).
-
Thomas Haller authored
For example, if you have a dnsmasq service running and bound to port 53, then NetworkManager's [main].dns=dnsmasq will fail to start. And we keep retrying to start it. But then update pending would hang indefinitely, and devices could not become active. That must not happen. Give the DNS update only 5 seconds. If it's not done by then, assume we have a problem and unblock.
-
Thomas Haller authored
We want to know when we are busy (have an update pending or on-going). Implement that.
-
Thomas Haller authored
-
Thomas Haller authored
The "unbound" DNS plugin was very rudimentary and is deprecated since commit 4a2fe098 ('man: mark [main].dns=unbound as deprecated') (Jun 2021). It is part of dnssec-trigger tool, but the dnssec-trigger tool doesn't actually use it. Instead it installs a dispatcher script "/usr/lib/NetworkManager/dispatcher.d/01-dnssec-trigger". Especially, since the plugin requires "/usr/libexec/dnssec-trigger-script", which is provided by "dnssec-trigger" package on Fedora. At the same time, the package provides the dispatcher script. So I don't this works or anybody is using this. https://mail.gnome.org/archives/networkmanager-list/2022-April/msg00002.html
-
Thomas Haller authored
-
Thomas Haller authored
This is used to signal that an update is pending or in progress. For this to work, we also need to implement the stop() handle. Otherwise, we couldn't abort pending requests, which is necessary during shutdown (not today, but in the future).
-
Thomas Haller authored
CList is a great, simple data structure. Especially, if we can embed it into the data we track. Here we just create a (temporary) list of pointers. A GPtrArray is the better data structure for that.
-
Thomas Haller authored
We copy the content of the hash table to an array, so that we can sort the entries and they have a defined order. We are not only interested in the keys, but the keys and the values. Hence, use nm_utils_hash_to_array_with_buffer() which gives both at the same time.
-
Thomas Haller authored
When we do something where the order makes a visible difference, we should do it in a consistent way, that does not depend on arbitray things. Sort the ifindexes from dirty_interfaces hash table.
-
Thomas Haller authored
-
Thomas Haller authored
-
Thomas Haller authored
-
Thomas Haller authored
Theoretically, this should be a GObject property, and not a signal. But then I'd also have to implement the get_property() function, which is more hazzle than necessary. A signal will do nicely.
-
Thomas Haller authored
Currently NMDnsSystemdResolved does not implement "stop()". That is about to change. Make sure to call stop before unreferencing the instance.
-
Thomas Haller authored
NM_DNS_PLUGIN_GET_PRIVATE() macro was broken. Also NMDnsPluginPrivate contained unused fields. Fix that. The private data is unused at the moment, but will be used next. Hence it is fixed and not removed.
-
Thomas Haller authored
-
Thomas Haller authored
We avoid printing raw pointer values. Also, in this case this is a singleton, and we only create one instance of this type. Note that we would still have printed the pointer instance while constructing the instances, before setting it as singleton. Just drop this.
-
Thomas Haller authored
nm_shutdown_wait_obj_register_object() today has no practical effect. In the future it will block shutdown until the object gets destroyed. We will want that NMDnsPlugin gets wrapped up during shut down, before quitting.
-
Thomas Haller authored
We effectively already have this function, with the name nm_utils_named_values_from_strdict(). Which is a decent name, if you have a strdict. But it seems odd to use for other dictionaries. Instead, add a variant with a different name. Naming is important, and just to have the better name, the function is effectively duplicated.
-
- 14 Apr, 2022 10 commits
-
-
Thomas Haller authored
NMUtilsNamedValue is a key-value tuple, usually the key is a string (hence the name "Named"). But this struct is also useful for keys that are not strings. Add another "name_ptr" union field to access the key that way. The alternative would be to add another struct, which serves a very similar purpose though.
-
-
Thomas Haller authored
This code is now unused.
-
Thomas Haller authored
This is long replaced by nettools' n-dhcp4 client. Drop it. We still require NMDhcpSystemd for the DHCPv6 client. Note that "[main].dhcp=systemd" now falls back to the internal client. But this option was undocumented and internal anyway.
-
Thomas Haller authored
-
Thomas Haller authored
We write lease files for internal DHCP client ("systemd" and "nettools") in a systemd-specific format. We want to drop systemd code, so we need to have our own parsing code. Granted, nettools only writes a single "ADDRESS=" line, so parsing that would be easy. On the other hand, systemd's parser is not complicated either (in particular, if we can steal their implementation). Also, it's a commonly used format in systemd, so having the parser would allow us to parse similar formats. Also, we could opt to choose that format, where it makes sense.
-
Thomas Haller authored
-
Thomas Haller authored
-
Thomas Haller authored
-
Thomas Haller authored
On recent Fedora and RHEL we no longer have differing "rpm_version" and "real_version". So usually "rpm_version" is just the same as "real_version". Update the template spec file to reflect that. For the "build_clean.sh" script, we anyway always set them both to "__VERSION__".
-
- 13 Apr, 2022 3 commits
-
-
Thomas Haller authored
git subtree pull --prefix src/c-stdaux git@github.com:c-util/c-stdaux.git main --squash
-
Thomas Haller authored
f20e1cf2dfb1 build: verify cflags do not contain spaces 5333735eeb74 build: export cflags via declare_dependency() d050374b1c1a build: export basic CFLAGS git-subtree-dir: src/c-stdaux git-subtree-split: f20e1cf2dfb177e77cc946331ed2d2a83169d8b9
-
Thomas Haller authored
git subtree pull --prefix src/c-stdaux git@github.com:c-util/c-stdaux.git main --squash
-