[SCM] Socket Wrapper Repository - branch master updated

2023-01-17 Thread Andreas Schneider
The branch, master has been updated
   via  5e4b246 tests: test uid_wrapper_syscall_{valid,va} interaction 
using swrap_fake_uid_wrapper.so
   via  a4e2437 src/socket_wrapper.c: make use of 
uid_wrapper_syscall_{valid,va}()
   via  1b8d5d8 src/socket_wrapper.c: export 
socket_wrapper_syscall_{valid,va}()
   via  79ce9b9 tests: let test_echo_tcp_sendmmsg_recvmmsg check raw 
SYS_close, SYS_recvmmsg and SYS_sendmmsg
   via  72da1a7 src/socket_wrapper.c: handle raw SYS_close, SYS_recvmmsg 
and SYS_sendmmsg syscall() invocations
   via  7fbf20d tests: add test_echo_tcp_sendmmsg_recvmmsg
   via  f9342dc src/socket_wrapper.c: implement recvmmsg and sendmmsg
   via  d04424e src/socket_wrapper.c: add some tracing for connected dgram 
sockets
   via  6af6c5e src/socket_wrapper.c: don't leak unlink() errno (most 
likely ENOENT) in swrap_bind()
   via  2f67c6b src/socket_wrapper.c: pretty print ip addresses in tracing 
output.
  from  f88fe92 Bump version to 1.3.5

https://git.samba.org/?p=socket_wrapper.git;a=shortlog;h=master


- Log -
commit 5e4b2466d291f37a6deb1b4c7ae56d76b4402557
Author: Stefan Metzmacher 
Date:   Mon Jan 16 21:57:35 2023 +0100

tests: test uid_wrapper_syscall_{valid,va} interaction using 
swrap_fake_uid_wrapper.so

Signed-off-by: Stefan Metzmacher 
Reviewed-by: Andreas Schneider 

commit a4e2437d5f0a89880d45c2cf685f3e81654a23a7
Author: Stefan Metzmacher 
Date:   Mon Jan 16 19:51:05 2023 +0100

src/socket_wrapper.c: make use of uid_wrapper_syscall_{valid,va}()

If we find uid_wrapper_syscall_{valid,va}() symbols in the already
loaded libraries, we'll try to hand over syscall() invocations to
uid_wrapper.

Signed-off-by: Stefan Metzmacher 
Reviewed-by: Andreas Schneider 

commit 1b8d5d8c6e0bd56ec4883e2b09f4f2cedd3aa1d7
Author: Stefan Metzmacher 
Date:   Mon Jan 16 19:48:57 2023 +0100

src/socket_wrapper.c: export socket_wrapper_syscall_{valid,va}()

We need to hook into syscall() from socket_wrapper as well as
from uid_wrapper() (and maybe others in future).
But the assumption is that only one wrapper will take care
of a single syscall number.

So we provide socket_wrapper_syscall_valid() in order to allow
external consumers (e.g. uid_wrapper.so) to check if
socket_wrapper wants to handle a specified syscall number.

And we provide socket_wrapper_syscall_va() in order to allow
calling into swrap_syscall().

Signed-off-by: Stefan Metzmacher 
Reviewed-by: Andreas Schneider 

commit 79ce9b9b14ac83a33712d6af4eecdb63bba45742
Author: Stefan Metzmacher 
Date:   Mon Jan 16 20:14:26 2023 +0100

tests: let test_echo_tcp_sendmmsg_recvmmsg check raw SYS_close, 
SYS_recvmmsg and SYS_sendmmsg

Signed-off-by: Stefan Metzmacher 
Reviewed-by: Andreas Schneider 

commit 72da1a76e78bcf9be733ec72cce7060a6e19606a
Author: Stefan Metzmacher 
Date:   Mon Jan 16 19:46:13 2023 +0100

src/socket_wrapper.c: handle raw SYS_close, SYS_recvmmsg and SYS_sendmmsg 
syscall() invocations

This fixes a problem hit by 'nsupdate -g' and bind9 (dnsutils). If bind is 
built
against libuv <= 1.44.2 it will not use sendmmsg/recvmmsg functions from 
libc
but use the corresponding syscalls directly. Newer version of libuv removed
the syscall wrappers and use sendmmsg/recvmmsg from libc.

Signed-off-by: Stefan Metzmacher 
Reviewed-by: Andreas Schneider 

commit 7fbf20da01e9cc2031e92111bc794048a13d5f50
Author: Stefan Metzmacher 
Date:   Mon Jan 16 19:27:12 2023 +0100

tests: add test_echo_tcp_sendmmsg_recvmmsg

Signed-off-by: Stefan Metzmacher 
Reviewed-by: Andreas Schneider 

commit f9342dcf3d9a163dd9f3aee324a14a3ac0d423ac
Author: Stefan Metzmacher 
Date:   Mon Jan 16 17:00:48 2023 +0100

src/socket_wrapper.c: implement recvmmsg and sendmmsg

Signed-off-by: Stefan Metzmacher 
Reviewed-by: Andreas Schneider 

commit d04424e0baddc969d06623e38a67937cb2c83587
Author: Stefan Metzmacher 
Date:   Mon Jan 16 16:58:04 2023 +0100

src/socket_wrapper.c: add some tracing for connected dgram sockets

Signed-off-by: Stefan Metzmacher 
Reviewed-by: Andreas Schneider 

commit 6af6c5e59a9b522294c3a83a3efb0eccc1211087
Author: Stefan Metzmacher 
Date:   Sun Nov 6 16:07:21 2022 +0100

src/socket_wrapper.c: don't leak unlink() errno (most likely ENOENT) in 
swrap_bind()

This fixes a problem hit by 'nsupdate -g' from the
bind9-dnsutils 1:9.18.1-1ubuntu1.2 package.

Signed-off-by: Stefan Metzmacher 
Reviewed-by: Andreas Schneider 

commit 2f67c6bef20e58676851df668f70fd261eea89ea
Author: Stefan Metzmacher 
Date:   Mon Jan 16 16:50:32 2023 +0100

src/socket_wrapper.c: pretty print ip addresses in tracing output.

Signed-off-by: Stefan Metzmacher 
Reviewed-by: Andreas Schneider 


[SCM] Samba Shared Repository - branch master updated

2023-01-17 Thread Björn Baumbach
The branch, master has been updated
   via  8fbadada8c0 lib/tsocket: fix a typo in the tsocket guide doc
   via  1289575af2c s3/libsmb: fix a typo in parameter description
   via  5a017b113ed samba-tool domain: fix a typo in samba-tool 
passwordsettings option description
   via  86fde91621b auth/creds: fix a typo in a comment
  from  3d3d01cda8d s3: smbd: Tweak openat_pathref_dirfsp_nosymlink() to 
NULL out fsp->fsp_name after calling fd_close() on intermediate directories, 
rather than before.

https://git.samba.org/?p=samba.git;a=shortlog;h=master


- Log -
commit 8fbadada8c00ff7df311bd7868011f01e797a4e8
Author: Björn Baumbach 
Date:   Tue Jan 17 12:28:36 2023 +0100

lib/tsocket: fix a typo in the tsocket guide doc

Signed-off-by: Björn Baumbach 
Reviewed-by: Ralph Boehme 

Autobuild-User(master): Björn Baumbach 
Autobuild-Date(master): Tue Jan 17 18:23:18 UTC 2023 on sn-devel-184

commit 1289575af2c99d8abd5abfd5d1f90d1664d3e7f2
Author: Björn Baumbach 
Date:   Tue Jan 17 12:29:28 2023 +0100

s3/libsmb: fix a typo in parameter description

Signed-off-by: Björn Baumbach 
Reviewed-by: Ralph Boehme 

commit 5a017b113ed902eb73f2233321d1fbe8d97c10c8
Author: Björn Baumbach 
Date:   Tue Jan 17 12:27:01 2023 +0100

samba-tool domain: fix a typo in samba-tool passwordsettings option 
description

Signed-off-by: Björn Baumbach 
Reviewed-by: Ralph Boehme 

commit 86fde91621b9190df1a8df290441575ca284e6ed
Author: Björn Baumbach 
Date:   Tue Jan 17 12:26:10 2023 +0100

auth/creds: fix a typo in a comment

Signed-off-by: Björn Baumbach 
Reviewed-by: Ralph Boehme 

---

Summary of changes:
 auth/credentials/credentials_cmdline.c | 2 +-
 lib/tsocket/tsocket_guide.txt  | 2 +-
 python/samba/netcmd/domain.py  | 2 +-
 source3/libsmb/cliconnect.c| 2 +-
 4 files changed, 4 insertions(+), 4 deletions(-)


Changeset truncated at 500 lines:

diff --git a/auth/credentials/credentials_cmdline.c 
b/auth/credentials/credentials_cmdline.c
index 11b1ab9ecd2..c8c7c183c22 100644
--- a/auth/credentials/credentials_cmdline.c
+++ b/auth/credentials/credentials_cmdline.c
@@ -65,7 +65,7 @@ fail:
 bool cli_credentials_set_cmdline_callbacks(struct cli_credentials *cred)
 {
/*
-* The there is no tty, then we will try to read the password from
+* If there is no tty, we will try to read the password from
 * stdin.
 */
return cli_credentials_set_password_callback(cred,
diff --git a/lib/tsocket/tsocket_guide.txt b/lib/tsocket/tsocket_guide.txt
index afd0bd37dbc..7c925d4f1db 100644
--- a/lib/tsocket/tsocket_guide.txt
+++ b/lib/tsocket/tsocket_guide.txt
@@ -216,7 +216,7 @@ state for this function. The tstream_readv_pdu engine will 
ask
 the next_vector function for the next iovec vector to be used.
 There is a tstream_readv_send/recv pair for each vector returned
 by the next_vector function. If the next_vector function detects
-it received a full pdu, it returns an empty vector. The the callback
+it received a full pdu, it returns an empty vector. The callback
 of the tevent_req (returned by tstream_readv_pdu_send()) is triggered.
 Note: the buffer allocation is completely up to the next_vector function
 and its private state.
diff --git a/python/samba/netcmd/domain.py b/python/samba/netcmd/domain.py
index cf8c089c13d..582a17f0fff 100644
--- a/python/samba/netcmd/domain.py
+++ b/python/samba/netcmd/domain.py
@@ -1352,7 +1352,7 @@ class cmd_domain_passwordsettings_set(Command):
 Option("--max-pwd-age",
help="The maximum password age ( | default).  
Default is 43.", type=str),
 Option("--account-lockout-duration",
-   help="The length of time an account is locked out after 
exeeding the limit on bad password attempts ( | default).  
Default is 30 mins.", type=str),
+   help="The length of time an account is locked out after 
exceeding the limit on bad password attempts ( | default).  
Default is 30 mins.", type=str),
 Option("--account-lockout-threshold",
help="The number of bad password attempts allowed before 
locking out the account ( | default).  Default is 0 (never lock 
out).", type=str),
 Option("--reset-account-lockout-after",
diff --git a/source3/libsmb/cliconnect.c b/source3/libsmb/cliconnect.c
index edbd2477f60..b687a22e11c 100644
--- a/source3/libsmb/cliconnect.c
+++ b/source3/libsmb/cliconnect.c
@@ -2786,7 +2786,7 @@ static void cli_start_connection_done(struct tevent_req 
*subreq);
establishes a connection to after the negprot. 
@param output_cli A fully initialised cli structure, non-null only on 
success
@param dest_host The netbios name of the remote host
-   @param dest_ss (optional) The the destination IP, NULL for name based lookup
+   

[SCM] UID Wrapper Repository - annotated tag uid_wrapper-1.3.0 created

2023-01-17 Thread Andreas Schneider
The annotated tag, uid_wrapper-1.3.0 has been created
at  2e6c2e61630f5e85e4574a171e4451233a2db57e (tag)
   tagging  0e0e6eff6488f3bb6a1c55ad8f92b2ea6ee3 (commit)
  replaces  uid_wrapper-1.2.9
 tagged by  Andreas Schneider
on  Tue Jan 17 14:54:27 2023 +0100

- Log -
uid_wrapper-1.3.0

* Added support to interact with socket_wrapper syscall()
* Fixed deadlocks with threads
* Improved log output
-BEGIN PGP SIGNATURE-

iQIzBAABCgAdFiEEjf9T4Y8qvI2PPJIjfuD8TcwBTj0FAmPGqKoACgkQfuD8TcwB
Tj1a/xAAkrWNmdSJ4gHaddkzkPAHxxn93db7b1mCzo6zWUdpMVGfEfCuKGlPedO3
tI8MnsAm3JHinQ6xoyb8JzWLeBbFMhkmrf3ApIAwBK94R3PJ/10sOQlj2O5et7eX
Iy5HCjLibztpHQ1mDIjwzc7AIjCOF1U5PDi36IC8iv8/G4L3Y3jRXyAuAKRMzW9N
cEvSZo1aPa85l6XddYi9Ag8exYvt+46oQ35pL7digG7Q7kfc3BeGoKeSSgshyNL7
TJ6l7Zc3UOqPLPYssMcHkLJtXC8FnO2YdPwRl9RhKFazocNXbgNoppEHHubeEHmb
LA/uBGN2uzXPKG0rBD+KHge2t2SzLlu+fk6n+cZgqjBeFaSgDhisGHZcKx+ttqo2
C812+WQb86zu0M8AI5JIIPKX4ECjuCkpy35qOhSZ4ha0+2puEvnJDeRNena3PVLS
XSQS6NfWcl44oJf0JSdFpyf7pMhc373f1dJp4QSvYCEUYAiLHUQ/kAUA2gJSdbcK
oysUea3heFDKGktulUqHRhCYGyQMyUrUWNbkrU0zwqPdse3x0fkrPsc8WBVOmZjo
4dTCLSFLKjElkKq43ldYbuPEhriFDvd8QhFw8rEg6tqIulh7LPE8Fq5a6101QnNc
iXEn7BF6K2UNBVzxoMr8TwHcddQamwL18dMAX9yieqvpv3tp1wA=
=fJq4
-END PGP SIGNATURE-

Andreas Schneider (10):
  Add editorconfig
  Add clang-format config file
  cmake: Check for getprogname()
  cmake: Add -DCMAKE_BUILD_TYPE=ThreadSanitizer
  cmake: Disable deepbind if we run with sanitizers
  gitlab-ci: Format yml correctly that ymllint is happy
  gitlab-ci: Introduce stages
  gitlab-ci: Add runner with ThreadSanitizer
  Rename to CHANGELOG
  Bump version to 1.3.0

Samuel Thibault (1):
  src/uid_wrapper.c: Avoid dclose(RTLD_NEXT)

Stefan Metzmacher (13):
  src/uid_wrapper.c: remove unused UWRAP_LIBSOCKET and UWRAP_LIBNSL
  src/uid_wrapper.c: also log the process name
  tests: fix locking in test_thread_setuid.c
  tests: fix data race in test_thread_sync_setreuid.c
  src/uid_wrapper.c: always go through uwrap_bind_symbol_all() protected by 
pthread_once()
  src/uid_wrapper.c: fix RTLD_NEXT handling for libpthread
  src/uid_wrapper.c: force RTLD_NEXT for pthread_create/exit() if available
  src/uid_wrapper.c: check for uid_wrapper related syscall numbers before 
uid_wrapper_enabled()
  src/uid_wrapper.c: fix mutex fork handling
  src/uid_wrapper.c: export uid_wrapper_syscall_{valid,va}()
  src/uid_wrapper.c: make use of socket_wrapper_syscall_{valid,va}()
  tests: test socket_wrapper_syscall_{valid,va} interaction using 
uwrap_fake_socket_wrapper.so
  gitlab-ci: run .gitlab-ci.yml also on branches@metze/uid_wrapper

---


-- 
UID Wrapper Repository



[SCM] UID Wrapper Repository - branch master updated

2023-01-17 Thread Andreas Schneider
The branch, master has been updated
   via  0e0 Bump version to 1.3.0
   via  e6abc78 Rename to CHANGELOG
  from  2e0adc7 gitlab-ci: run .gitlab-ci.yml also on 
branches@metze/uid_wrapper

https://git.samba.org/?p=uid_wrapper.git;a=shortlog;h=master


- Log -
commit 0e0e6eff6488f3bb6a1c55ad8f92b2ea6ee3
Author: Andreas Schneider 
Date:   Tue Jan 17 14:39:42 2023 +0100

Bump version to 1.3.0

Signed-off-by: Andreas Schneider 
Reviewed-by: Stefan Metzmacher 

commit e6abc78dbd28d554e2c07e0d9ef93dd3e97199b2
Author: Andreas Schneider 
Date:   Tue Jan 17 14:36:14 2023 +0100

Rename to CHANGELOG

Reviewed-by: Stefan Metzmacher 

---

Summary of changes:
 ChangeLog => CHANGELOG | 9 +++--
 CMakeLists.txt | 4 ++--
 2 files changed, 9 insertions(+), 4 deletions(-)
 rename ChangeLog => CHANGELOG (91%)


Changeset truncated at 500 lines:

diff --git a/ChangeLog b/CHANGELOG
similarity index 91%
rename from ChangeLog
rename to CHANGELOG
index 3b5f1e8..92542f5 100644
--- a/ChangeLog
+++ b/CHANGELOG
@@ -1,5 +1,10 @@
-ChangeLog
-==
+CHANGELOG
+=
+
+version 1.3.0 (released 2023-01-17)
+  * Added support to interact with socket_wrapper syscall()
+  * Fixed deadlocks with threads
+  * Improved log output
 
 version 1.2.9 (released 2021-12-02)
   * Add support for getgroups_chk()
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 457dd72..c11220a 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -11,7 +11,7 @@ list(APPEND CMAKE_MODULE_PATH 
"${CMAKE_CURRENT_SOURCE_DIR}/cmake/Modules")
 include(DefineCMakeDefaults)
 include(DefineCompilerFlags)
 
-project(uid_wrapper VERSION 1.2.9 LANGUAGES C)
+project(uid_wrapper VERSION 1.3.0 LANGUAGES C)
 
 # global needed variables
 set(APPLICATION_NAME ${PROJECT_NAME})
@@ -23,7 +23,7 @@ set(APPLICATION_NAME ${PROJECT_NAME})
 # Increment AGE. Set REVISION to 0
 #   If the source code was changed, but there were no interface changes:
 # Increment REVISION.
-set(LIBRARY_VERSION "0.1.0")
+set(LIBRARY_VERSION "0.2.0")
 set(LIBRARY_SOVERSION "0")
 
 # add definitions


-- 
UID Wrapper Repository



[SCM] UID Wrapper Repository - branch master updated

2023-01-17 Thread Andreas Schneider
The branch, master has been updated
   via  2e0adc7 gitlab-ci: run .gitlab-ci.yml also on 
branches@metze/uid_wrapper
   via  465806a gitlab-ci: Add runner with ThreadSanitizer
   via  c2c4339 gitlab-ci: Introduce stages
   via  cacb76a gitlab-ci: Format yml correctly that ymllint is happy
   via  a86fe7e cmake: Disable deepbind if we run with sanitizers
   via  5541386 cmake: Add -DCMAKE_BUILD_TYPE=ThreadSanitizer
   via  6d309f8 tests: test socket_wrapper_syscall_{valid,va} interaction 
using uwrap_fake_socket_wrapper.so
   via  f9aeff7 src/uid_wrapper.c: make use of 
socket_wrapper_syscall_{valid,va}()
   via  da63f38 src/uid_wrapper.c: export uid_wrapper_syscall_{valid,va}()
   via  759f431 src/uid_wrapper.c: fix mutex fork handling
   via  681eb37 src/uid_wrapper.c: check for uid_wrapper related syscall 
numbers before uid_wrapper_enabled()
   via  1c7324b src/uid_wrapper.c: force RTLD_NEXT for 
pthread_create/exit() if available
   via  cf818b5 src/uid_wrapper.c: fix RTLD_NEXT handling for libpthread
   via  30bbcea src/uid_wrapper.c: Avoid dclose(RTLD_NEXT)
   via  15627c3 src/uid_wrapper.c: always go through 
uwrap_bind_symbol_all() protected by pthread_once()
   via  b2dff92 tests: fix data race in test_thread_sync_setreuid.c
   via  206542f tests: fix locking in test_thread_setuid.c
   via  9adb464 src/uid_wrapper.c: also log the process name
   via  1cc448d cmake: Check for getprogname()
   via  fb887e3 src/uid_wrapper.c: remove unused UWRAP_LIBSOCKET and 
UWRAP_LIBNSL
  from  6223b58 Add clang-format config file

https://git.samba.org/?p=uid_wrapper.git;a=shortlog;h=master


- Log -
commit 2e0adc7a0a6cdfe479a8225aa03d0286a1ef2b96
Author: Stefan Metzmacher 
Date:   Sat Jan 14 11:28:54 2023 +0100

gitlab-ci: run .gitlab-ci.yml also on branches@metze/uid_wrapper

Signed-off-by: Stefan Metzmacher 
Reviewed-by: Andreas Schneider 

commit 465806ac345a1599bb21202d6311b9fddb3f8096
Author: Andreas Schneider 
Date:   Sat Jan 14 09:39:44 2023 +0100

gitlab-ci: Add runner with ThreadSanitizer

Signed-off-by: Andreas Schneider 
Reviewed-by: Andreas Schneider 

commit c2c4339d62ddcc64262681474dd9bc16d3b5dbce
Author: Andreas Schneider 
Date:   Sat Jan 14 09:36:26 2023 +0100

gitlab-ci: Introduce stages

Signed-off-by: Andreas Schneider 
Reviewed-by: Andreas Schneider 

commit cacb76add5022583e0db16cb1cce0d2483157a35
Author: Andreas Schneider 
Date:   Sat Jan 14 09:33:45 2023 +0100

gitlab-ci: Format yml correctly that ymllint is happy

Signed-off-by: Andreas Schneider 
Reviewed-by: Andreas Schneider 

commit a86fe7ebb737045cfb90a618a54e4429f6168a08
Author: Andreas Schneider 
Date:   Sat Jan 14 09:30:17 2023 +0100

cmake: Disable deepbind if we run with sanitizers

Signed-off-by: Andreas Schneider 
Reviewed-by: Andreas Schneider 

commit 5541386b1ffe7bd5561221c7f1931126fb6586b9
Author: Andreas Schneider 
Date:   Sat Jan 14 09:21:55 2023 +0100

cmake: Add -DCMAKE_BUILD_TYPE=ThreadSanitizer

Signed-off-by: Andreas Schneider 
Reviewed-by: Andreas Schneider 

commit 6d309f8b31493766f99d5f288550b1c33100bde8
Author: Stefan Metzmacher 
Date:   Mon Jan 16 21:41:09 2023 +0100

tests: test socket_wrapper_syscall_{valid,va} interaction using 
uwrap_fake_socket_wrapper.so

Signed-off-by: Stefan Metzmacher 
Reviewed-by: Andreas Schneider 

commit f9aeff77b2b2e7776f13239bab548bb5af717f8a
Author: Stefan Metzmacher 
Date:   Mon Jan 16 11:22:02 2023 +0100

src/uid_wrapper.c: make use of socket_wrapper_syscall_{valid,va}()

If we find socket_wrapper_syscall_{valid,va}() symbols in the already
loaded libraries, we'll try to hand over syscall() invocations to
socket_wrapper.

Signed-off-by: Stefan Metzmacher 
Reviewed-by: Andreas Schneider 

commit da63f387bf85da1ad95b112fb3ef513399b2254c
Author: Stefan Metzmacher 
Date:   Mon Jan 16 11:42:05 2023 +0100

src/uid_wrapper.c: export uid_wrapper_syscall_{valid,va}()

We need to hook into syscall() from uid_wrapper as well as
from socket_wrapper() (and maybe others in future).
But the assumption is that only one wrapper will take care
of a single syscall number.

So we provide uid_wrapper_syscall_valid() in order to allow
external consumers (e.g. socket_wrapper.so) to check if
uid_wrapper wants to handle a specified syscall number.

And we provide uid_wrapper_syscall_va() in order to allow
calling into uwrap_syscall().

Signed-off-by: Stefan Metzmacher 
Reviewed-by: Andreas Schneider 

commit 759f4317756b4c70cbf1943ff66a4c714a7e5030
Author: Stefan Metzmacher 
Date:   Tue Nov 8 20:31:35 2022 +0100

src/uid_wrapper.c: fix mutex fork handling

We need to use pthread_mutex_init in the child handler...
See 

[SCM] UID Wrapper Repository - branch master updated

2023-01-17 Thread Andreas Schneider
The branch, master has been updated
   via  6223b58 Add clang-format config file
   via  4681e51 Add editorconfig
  from  a9189e2 Bump version to 1.2.9

https://git.samba.org/?p=uid_wrapper.git;a=shortlog;h=master


- Log -
commit 6223b58f5942d6d245ba696871c193e8f5c4313c
Author: Andreas Schneider 
Date:   Tue Jan 17 11:11:04 2023 +0100

Add clang-format config file

Signed-off-by: Andreas Schneider 
Reviewed-by: Stefan Metzmacher 

commit 4681e51bc0285b6ad77ecdf95cf6c1e6bb53a6ee
Author: Andreas Schneider 
Date:   Tue Jan 17 11:10:28 2023 +0100

Add editorconfig

Signed-off-by: Andreas Schneider 
Reviewed-by: Stefan Metzmacher 

---

Summary of changes:
 .clang-format | 26 ++
 .editorconfig | 23 +++
 2 files changed, 49 insertions(+)
 create mode 100644 .clang-format
 create mode 100644 .editorconfig


Changeset truncated at 500 lines:

diff --git a/.clang-format b/.clang-format
new file mode 100644
index 000..5385807
--- /dev/null
+++ b/.clang-format
@@ -0,0 +1,26 @@
+# https://clang.llvm.org/docs/ClangFormatStyleOptions.html
+BasedOnStyle: LLVM
+IndentWidth: 8
+ContinuationIndentWidth: 8
+UseTab: true
+BreakBeforeBraces: Custom
+BraceWrapping:
+AfterEnum: false
+AfterFunction: true
+AfterStruct: false
+AfterUnion: false
+AfterExternBlock: true
+BeforeElse: false
+BeforeWhile: false
+AllowShortIfStatementsOnASingleLine: false
+ColumnLimit: 80
+IndentCaseLabels: false
+AlignAfterOpenBracket: Align
+BinPackParameters: false
+BinPackArguments: false
+AllowAllParametersOfDeclarationOnNextLine: false
+AllowAllArgumentsOnNextLine: false
+AllowShortFunctionsOnASingleLine: Empty
+AlwaysBreakAfterReturnType: None
+AlignEscapedNewlines: Left
+SortIncludes: false
diff --git a/.editorconfig b/.editorconfig
new file mode 100644
index 000..bbe1bd5
--- /dev/null
+++ b/.editorconfig
@@ -0,0 +1,23 @@
+root = true
+
+[*]
+charset = utf-8
+max_line_length = 80
+end_of_line = lf
+trim_trailing_whitespace = true
+insert_final_newline = true
+
+[*.{c,h}]
+indent_style = tab
+indent_size = 8
+tab_width = 8
+
+[*.cmake]
+indent_style = space
+indent_size = 4
+tab_width = 4
+
+[CMake*]
+indent_style = space
+indent_size = 4
+tab_width = 4


-- 
UID Wrapper Repository