summaryrefslogtreecommitdiffhomepage
path: root/src/logic
diff options
context:
space:
mode:
authormidipix <writeonce@midipix.org>2021-04-16 09:22:34 +0000
committermidipix <writeonce@midipix.org>2021-04-16 10:24:25 +0000
commitbd56f89f1a29adcefa7c9836a5ff4f5e78f45be6 (patch)
tree81b837f74a0544994f24a7febe72459bf0c991f7 /src/logic
parent430d5ab66c4a03939bad4d2fd8437260de8edc19 (diff)
downloadslibtool-bd56f89f1a29adcefa7c9836a5ff4f5e78f45be6.tar.bz2
slibtool-bd56f89f1a29adcefa7c9836a5ff4f5e78f45be6.tar.xz
Coding style meditation.
Diffstat (limited to 'src/logic')
-rw-r--r--src/logic/slbt_exec_link.c13
1 files changed, 6 insertions, 7 deletions
diff --git a/src/logic/slbt_exec_link.c b/src/logic/slbt_exec_link.c
index 59eebd4..3836f14 100644
--- a/src/logic/slbt_exec_link.c
+++ b/src/logic/slbt_exec_link.c
@@ -397,7 +397,7 @@ static void slbt_emit_fdwrap_dl_path_fixup(
dpfixup[0] = 0; strncat(dpfixup,"${0%/*}",dpfixup_size - 1);
/* append parent directory fixup for each level of depth in wrapper_dname */
- for (p=wrapper_dname,q=NULL; *p; ) {
+ for (p=wrapper_dname,q=0; *p; ) {
if ((p[0] == '.') && (p[1] == '/')) {
p++; p++;
} else if ((q = strchr(p, '/'))) {
@@ -1660,13 +1660,12 @@ static int slbt_exec_link_create_executable(
verinfo = slbt_source_version();
/* cwd, DL_PATH fixup */
- if (slbt_realpath(fdcwd,".",O_DIRECTORY,cwd,sizeof(cwd))) {
+ if (slbt_realpath(fdcwd,".",O_DIRECTORY,cwd,sizeof(cwd)))
return SLBT_SYSTEM_ERROR(dctx,0);
- } else {
- slbt_emit_fdwrap_dl_path_fixup(
- cwd,dpfixup,sizeof(dpfixup),
- wrapper);
- }
+
+ slbt_emit_fdwrap_dl_path_fixup(
+ cwd,dpfixup,sizeof(dpfixup),
+ wrapper);
if (slbt_dprintf(fdwrap,
"#!/bin/sh\n"