~ubuntu-branches/debian/sid/frama-c/sid

« back to all changes in this revision

Viewing changes to tests/jessie/StrCpy.c

  • Committer: Bazaar Package Importer
  • Author(s): Mehdi Dogguy
  • Date: 2009-06-03 08:19:25 UTC
  • Revision ID: james.westby@ubuntu.com-20090603081925-kihvxvt0wy3zc4ar
Tags: upstream-20081201.dfsg
ImportĀ upstreamĀ versionĀ 20081201.dfsg

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#define CT_CAR_FIN_CHAINE '\0'
 
2
 
 
3
void StrCpy
 
4
    (char * const       Chaine1,
 
5
     const char * const Chaine2)
 
6
{
 
7
  char * pointeur       = Chaine1;
 
8
  const char * source   = Chaine2;
 
9
  while (*source)
 
10
    {
 
11
      *pointeur = *source;
 
12
      pointeur = pointeur + 1;
 
13
      source = source + 1;
 
14
    }
 
15
  *pointeur = CT_CAR_FIN_CHAINE;
 
16
  return;
 
17
}