File: getfacl-fix-uninitialized-variable.patch

package info (click to toggle)
acl 2.3.1-3
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 3,272 kB
  • sloc: ansic: 5,898; sh: 5,116; perl: 279; makefile: 51; sed: 16
file content (21 lines) | stat: -rw-r--r-- 602 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
Description: Fix usage of uninitialized variable.
Author: Vasily Gurevich <vas.gurevich@gmail.com>
Bug-Debian: https://bugs.debian.org/612599
Forwarded: yes
Last-Update: 2020-03-01

---
 tools/getfacl.c |    2 ++
 1 file changed, 2 insertions(+)

--- a/tools/getfacl.c
+++ b/tools/getfacl.c
@@ -381,6 +381,8 @@ int do_show(FILE *stream, const char *pa
 			show_line(stream, NULL, NULL, NULL, NULL,
 			          &dacl_names, dacl, &dacl_ent, dacl_mask);
 			continue;
+		} else if (!dacl && !acl) {
+			return -1;
 		} else {
 			if (acl_tag == ACL_USER || acl_tag == ACL_GROUP) {
 				int id_cmp = 0;