Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitb9cb132

Browse files
committed
Sync dlopen error handling for the *BSDs ... seems to me I've done this
before, but they were out of sync again. Per Kris Jurka.
1 parent6e2ff6e commitb9cb132

File tree

3 files changed

+6
-5
lines changed

3 files changed

+6
-5
lines changed

‎src/backend/port/dynloader/freebsd.c

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
/*-
1+
/*
22
* Portions Copyright (c) 1996-2005, PostgreSQL Global Development Group
33
* Portions Copyright (c) 1990 The Regents of the University of California.
44
* All rights reserved.
@@ -37,12 +37,13 @@ static char sccsid[] = "@(#)dl.c5.4 (Berkeley) 2/23/91";
3737
#endif/* LIBC_SCCS and not lint */
3838

3939
#include"postgres.h"
40-
#include"dynloader.h"
4140

4241
#include<nlist.h>
4342
#include<link.h>
4443
#include<dlfcn.h>
4544

45+
#include"dynloader.h"
46+
4647
staticcharerror_message[BUFSIZ];
4748

4849
char*
@@ -67,7 +68,7 @@ BSD44_derived_dlopen(const char *file, int num)
6768

6869
if ((vp=dlopen((char*)file,num))==NULL)
6970
snprintf(error_message,sizeof(error_message),
70-
"dlopen'%s' failed. (%s)",file,dlerror());
71+
"dlopen(%s) failed: %s",file,dlerror());
7172
returnvp;
7273
#endif
7374
}

‎src/backend/port/dynloader/netbsd.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ BSD44_derived_dlopen(const char *file, int num)
6868

6969
if ((vp=dlopen((char*)file,num))==NULL)
7070
snprintf(error_message,sizeof(error_message),
71-
"dlopen (%s) failed",file);
71+
"dlopen (%s) failed: %s",file,dlerror());
7272
returnvp;
7373
#endif
7474
}

‎src/backend/port/dynloader/openbsd.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ BSD44_derived_dlopen(const char *file, int num)
6868

6969
if ((vp=dlopen((char*)file,num))==NULL)
7070
snprintf(error_message,sizeof(error_message),
71-
"dlopen (%s) failed",file);
71+
"dlopen (%s) failed: %s",file,dlerror());
7272
returnvp;
7373
#endif
7474
}

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp