Verified that the new version does not generated bogus lines on bionic:
root@lp-1892825-bionic:~# cp /etc/default/locale /tmp/locale root@lp-1892825-bionic:~# update-locale --locale-file /tmp/locale LANG = C.UTF-8 root@lp-1892825-bionic:~# diff -u /etc/default/locale /tmp/locale --- /etc/default/locale 2022-05-09 15:53:23.000000000 +0000 +++ /tmp/locale 2022-05-13 03:05:13.859996448 +0000 @@ -1 +1 @@ -LANG=C.UTF-8 +#LANG=C.UTF-8 root@lp-1892825-bionic:~# update-locale --locale-file /tmp/locale LANG=en_US.UTF-8 root@lp-1892825-bionic:~# diff -u /etc/default/locale /tmp/locale --- /etc/default/locale 2022-05-09 15:53:23.000000000 +0000 +++ /tmp/locale 2022-05-13 03:05:36.008238719 +0000 @@ -1 +1 @@ -LANG=C.UTF-8 +LANG=en_US.UTF-8 root@lp-1892825-bionic:~# update-locale --locale-file /tmp/locale LANG= root@lp-1892825-bionic:~# update-locale --locale-file /tmp/locale LANG root@lp-1892825-bionic:~# diff -u /etc/default/locale /tmp/locale --- /etc/default/locale 2022-05-09 15:53:23.000000000 +0000 +++ /tmp/locale 2022-05-13 03:05:43.680321932 +0000 @@ -1 +1 @@ -LANG=C.UTF-8 +#LANG= root@lp-1892825-bionic:~# cp /etc/default/locale /tmp/locale root@lp-1892825-bionic:~# update-locale --locale-file /tmp/locale LANG root@lp-1892825-bionic:~# diff -u /etc/default/locale /tmp/locale --- /etc/default/locale 2022-05-09 15:53:23.000000000 +0000 +++ /tmp/locale 2022-05-13 03:05:56.384458949 +0000 @@ -1 +1 @@ -LANG=C.UTF-8 +#LANG=C.UTF-8 root@lp-1892825-bionic:~# dpkg-query -W locales locales 2.27-3ubuntu1.6
Verified that the new version does not generated bogus lines on bionic:
root@lp- 1892825- bionic: ~# cp /etc/default/locale /tmp/locale 1892825- bionic: ~# update-locale --locale-file /tmp/locale LANG = C.UTF-8 1892825- bionic: ~# diff -u /etc/default/locale /tmp/locale 1892825- bionic: ~# update-locale --locale-file /tmp/locale LANG=en_US.UTF-8 1892825- bionic: ~# diff -u /etc/default/locale /tmp/locale 1892825- bionic: ~# update-locale --locale-file /tmp/locale LANG= 1892825- bionic: ~# update-locale --locale-file /tmp/locale LANG 1892825- bionic: ~# diff -u /etc/default/locale /tmp/locale 1892825- bionic: ~# cp /etc/default/locale /tmp/locale 1892825- bionic: ~# update-locale --locale-file /tmp/locale LANG 1892825- bionic: ~# diff -u /etc/default/locale /tmp/locale 1892825- bionic: ~# dpkg-query -W locales
root@lp-
root@lp-
--- /etc/default/locale 2022-05-09 15:53:23.000000000 +0000
+++ /tmp/locale 2022-05-13 03:05:13.859996448 +0000
@@ -1 +1 @@
-LANG=C.UTF-8
+#LANG=C.UTF-8
root@lp-
root@lp-
--- /etc/default/locale 2022-05-09 15:53:23.000000000 +0000
+++ /tmp/locale 2022-05-13 03:05:36.008238719 +0000
@@ -1 +1 @@
-LANG=C.UTF-8
+LANG=en_US.UTF-8
root@lp-
root@lp-
root@lp-
--- /etc/default/locale 2022-05-09 15:53:23.000000000 +0000
+++ /tmp/locale 2022-05-13 03:05:43.680321932 +0000
@@ -1 +1 @@
-LANG=C.UTF-8
+#LANG=
root@lp-
root@lp-
root@lp-
--- /etc/default/locale 2022-05-09 15:53:23.000000000 +0000
+++ /tmp/locale 2022-05-13 03:05:56.384458949 +0000
@@ -1 +1 @@
-LANG=C.UTF-8
+#LANG=C.UTF-8
root@lp-
locales 2.27-3ubuntu1.6