delorie.com/djgpp/doc/libc/libc_335.html   search  
libc.a reference

[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

fnmerge

Syntax

 
#include <dir.h>

void fnmerge (char *path, const char *drive, const char *dir,
		const char *name, const char *ext);

Description

This function constructs a file path from its components drive, dir, name, and ext. If any of these is a NULL pointer, it won't be used. Usually, the drive string should include the trailing colon `:', the dir string should include the trailing slash `/' or backslash `\', and the ext string should include the leading dot `.'. However, if any of these isn't present, fnmerge will add them.

See section fnsplit.

Return Value

None.

Portability

ANSI/ISO C No
POSIX No

Example

 
char buf[MAXPATH];
fnmerge(buf, "d:", "/foo/", "data", ".txt");


  webmaster     delorie software   privacy  
  Copyright © 2004     Updated Apr 2004