equal
deleted
inserted
replaced
1 /* |
1 /* |
2 * Copyright (c) 2001, 2018, Oracle and/or its affiliates. All rights reserved. |
2 * Copyright (c) 2001, 2019, Oracle and/or its affiliates. All rights reserved. |
3 * Copyright (c) 2012, 2018 SAP SE. All rights reserved. |
3 * Copyright (c) 2012, 2018 SAP SE. All rights reserved. |
4 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
4 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
5 * |
5 * |
6 * This code is free software; you can redistribute it and/or modify it |
6 * This code is free software; you can redistribute it and/or modify it |
7 * under the terms of the GNU General Public License version 2 only, as |
7 * under the terms of the GNU General Public License version 2 only, as |
683 if (statbuf.st_size > 0 && statbuf.st_ctime > oldest_ctime) { |
683 if (statbuf.st_size > 0 && statbuf.st_ctime > oldest_ctime) { |
684 |
684 |
685 if (statbuf.st_ctime > oldest_ctime) { |
685 if (statbuf.st_ctime > oldest_ctime) { |
686 char* user = strchr(dentry->d_name, '_') + 1; |
686 char* user = strchr(dentry->d_name, '_') + 1; |
687 |
687 |
688 if (oldest_user != NULL) FREE_C_HEAP_ARRAY(char, oldest_user); |
688 FREE_C_HEAP_ARRAY(char, oldest_user); |
689 oldest_user = NEW_C_HEAP_ARRAY(char, strlen(user)+1, mtInternal); |
689 oldest_user = NEW_C_HEAP_ARRAY(char, strlen(user)+1, mtInternal); |
690 |
690 |
691 strcpy(oldest_user, user); |
691 strcpy(oldest_user, user); |
692 oldest_ctime = statbuf.st_ctime; |
692 oldest_ctime = statbuf.st_ctime; |
693 } |
693 } |