get_extension(3alleg)

get_extension3alleg

Returns a pointer to the extension of a filename. allegro game programming library.

Usage

#include <allegro.h>

char *get_extension(const char *filename);

Overview

Finds out the extension of the filename (with or without path information). Example:

   get_executable_name(name, sizeof(name));
   allegro_message("The binary has the extension `%s'\n",
                   get_extension(name));

Return value

Returns a pointer to the portion of `filename' where the extension starts, or a pointer to the trailing null character if there is no filename or it doesn't have extension.

Releases

4 releases since Debian 3.1 (Sarge); the text changed 2 times.

  1. 3.1
  2. 4.0
  3. 5.0–6.0

From liballegro-doc 2:4.2.2-2.2 in Debian 6.0 (Squeeze). Parsed by carta from the page's man source.