mirror of
https://gitlab.com/apparmor/apparmor.git
synced 2025-03-04 00:14:44 +01:00
Cherrypick revision 2412 from trunk, store magic token in unsigned int
Original log: Store the aa_change_hat magic token in an unsigned long in the test suite The magic token used in the test suite is incorrectly stored as an int rather than unsigned long leading to failure like this: running changehat_misc /tmp/testlibCTcwOe/source/trusty/apparmor-2.8.95~2411/tests/regression/apparmor/prologue.inc: line 176: 20184 Killed $testexec "$@" > $outfile 2>&1 Error: changehat_twice failed. Test 'CHANGEHAT (subprofile->subprofile)' was expected to 'pass'. Reason for failure 'killed by signal 9' Signed-off-by: Seth Arnold <seth.arnold@canonical.com> Acked-by: Steve Beattie <steve@nxnw.org>
This commit is contained in:
parent
155bdd07af
commit
3df7f56154
2 changed files with 3 additions and 2 deletions
|
@ -22,7 +22,8 @@
|
|||
|
||||
int main(int argc, char *argv[])
|
||||
{
|
||||
int rc, magic;
|
||||
int rc;
|
||||
unsigned long magic;
|
||||
|
||||
if (argc != 5){
|
||||
fprintf(stderr, "usage: %s profile1 profile2 goodmagic|badmagic file\n",
|
||||
|
|
|
@ -87,7 +87,7 @@ int main(int argc, char *argv[]) {
|
|||
int filedes[2];
|
||||
int c, o;
|
||||
char buf[BUFSIZ];
|
||||
unsigned int magic_token = SD_ID_MAGIC+1;
|
||||
unsigned long magic_token = SD_ID_MAGIC+1;
|
||||
int manual = 0;
|
||||
int exit_hat = 0;
|
||||
char * manual_string;
|
||||
|
|
Loading…
Add table
Reference in a new issue