Skip to content

Commit 85a2fef

Browse files
committed
trace2: make tr2_dst_get_trace_fd() file-scope static
This function never had any external callers in its life, as it gets accessed always via functions like tr2_dst_trace_write_line() and tr2_dst_trace_want() that sit at higher level. Make it file-scope static. Signed-off-by: Junio C Hamano <[email protected]>
1 parent 847a286 commit 85a2fef

File tree

2 files changed

+5
-7
lines changed

2 files changed

+5
-7
lines changed

trace2/tr2_dst.c

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -309,7 +309,11 @@ static void tr2_dst_malformed_warning(struct tr2_dst *dst,
309309
tr2_sysenv_display_name(dst->sysenv_var), tgt_value);
310310
}
311311

312-
int tr2_dst_get_trace_fd(struct tr2_dst *dst)
312+
/*
313+
* Return the file descriptor for the DST.
314+
* If 0, the dst is closed or disabled.
315+
*/
316+
static int tr2_dst_get_trace_fd(struct tr2_dst *dst)
313317
{
314318
const char *tgt_value;
315319

trace2/tr2_dst.h

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -19,12 +19,6 @@ struct tr2_dst {
1919
*/
2020
void tr2_dst_trace_disable(struct tr2_dst *dst);
2121

22-
/*
23-
* Return the file descriptor for the DST.
24-
* If 0, the dst is closed or disabled.
25-
*/
26-
int tr2_dst_get_trace_fd(struct tr2_dst *dst);
27-
2822
/*
2923
* Return true if the DST is opened for writing.
3024
*/

0 commit comments

Comments
 (0)