Skip to content

Commit

Permalink
global: Rename get_shadow_line_from_server_v2 to get_shadow_line
Browse files Browse the repository at this point in the history
  • Loading branch information
donald committed May 7, 2021
1 parent 1b61c0d commit 7bba383
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion get_shadow_line.c
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ static int _get_shadow_line_from_server(char *user, char *buf, size_t buflen) {

#define BUFLEN_SPWD (1024)

int get_shadow_line_from_server_v2(char *user, char **line) {
int get_shadow_line(char *user, char **line) {
char *buffer _cleanup_(free_string) = malloc(BUFLEN_SPWD);
if (buffer == NULL)
return -1;
Expand Down
2 changes: 1 addition & 1 deletion get_shadow_line.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#ifndef _GET_SHADOW_LINE_H
#define _GET_SHADOW_LINE_H

int get_shadow_line_from_server_v2(char *user, char **line);
int get_shadow_line(char *user, char **line);

#endif /* _GET_SHADOW_LINE_H */
2 changes: 1 addition & 1 deletion libnss_mxshadow.c
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ enum nss_status _nss_mxshadow_getspnam_r(const char *name, struct spwd *spwd, ch

char *line _cleanup_(free_string) = NULL;

int status = get_shadow_line_from_server_v2((char *)name, &line);
int status = get_shadow_line((char *)name, &line);
if (status == -1) {
*errnop = errno;
return NSS_STATUS_UNAVAIL;
Expand Down
2 changes: 1 addition & 1 deletion test_server.c
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ int main(int argc, char **argv) {
return 1;
}
char *line;
int status = get_shadow_line_from_server_v2(argv[1], &line);
int status = get_shadow_line(argv[1], &line);
if (status == -1)
return 1;
if (line[0]) {
Expand Down

0 comments on commit 7bba383

Please sign in to comment.