Bash-4.2 Official Patch 30

2012-07-10 Thread Chet Ramey
 BASH PATCH REPORT
 =

Bash-Release:   4.2
Patch-ID:   bash42-030

Bug-Reported-by:Roman Rakus 
Bug-Reference-ID:   <4d7dd91e.7040...@redhat.com>
Bug-Reference-URL:  
http://lists.gnu.org/archive/html/bug-bash/2011-03/msg00126.html

Bug-Description:

When attempting to glob strings in a multibyte locale, and those strings
contain invalid multibyte characters that cause mbsnrtowcs to return 0,
the globbing code loops infinitely.

Patch (apply with `patch -p0'):

*** ../bash-4.2-patched/lib/glob/xmbsrtowcs.c   2010-05-30 18:36:27.0 
-0400
--- lib/glob/xmbsrtowcs.c   2011-03-22 16:06:47.0 -0400
***
*** 36,39 
--- 36,41 
  #if HANDLE_MULTIBYTE
  
+ #define WSBUF_INC 32
+ 
  #ifndef FREE
  #  define FREE(x) do { if (x) free (x); } while (0)
***
*** 149,153 
size_t wcnum;   /* Number of wide characters in WSBUF */
mbstate_t state;/* Conversion State */
!   size_t wcslength;   /* Number of wide characters produced by the 
conversion. */
const char *end_or_backslash;
size_t nms; /* Number of multibyte characters to convert at one time. */
--- 151,155 
size_t wcnum;   /* Number of wide characters in WSBUF */
mbstate_t state;/* Conversion State */
!   size_t n, wcslength;/* Number of wide characters produced by the 
conversion. */
const char *end_or_backslash;
size_t nms; /* Number of multibyte characters to convert at one time. */
***
*** 172,176 
tmp_p = p;
tmp_state = state;
!   wcslength = mbsnrtowcs(NULL, &tmp_p, nms, 0, &tmp_state);
  
/* Conversion failed. */
--- 174,189 
tmp_p = p;
tmp_state = state;
! 
!   if (nms == 0 && *p == '\\') /* special initial case */
!   nms = wcslength = 1;
!   else
!   wcslength = mbsnrtowcs (NULL, &tmp_p, nms, 0, &tmp_state);
! 
!   if (wcslength == 0)
!   {
! tmp_p = p;/* will need below */
! tmp_state = state;
! wcslength = 1;/* take a single byte */
!   }
  
/* Conversion failed. */
***
*** 187,191 
  wchar_t *wstmp;
  
! wsbuf_size = wcnum+wcslength+1;   /* 1 for the L'\0' or the 
potential L'\\' */
  
  wstmp = (wchar_t *) realloc (wsbuf, wsbuf_size * sizeof (wchar_t));
--- 200,205 
  wchar_t *wstmp;
  
! while (wsbuf_size < wcnum+wcslength+1) /* 1 for the L'\0' or the 
potential L'\\' */
!   wsbuf_size += WSBUF_INC;
  
  wstmp = (wchar_t *) realloc (wsbuf, wsbuf_size * sizeof (wchar_t));
***
*** 200,207 
  
/* Perform the conversion. This is assumed to return 'wcslength'.
!* It may set 'p' to NULL. */
!   mbsnrtowcs(wsbuf+wcnum, &p, nms, wsbuf_size-wcnum, &state);
  
!   wcnum += wcslength;
  
if (mbsinit (&state) && (p != NULL) && (*p == '\\'))
--- 214,229 
  
/* Perform the conversion. This is assumed to return 'wcslength'.
!It may set 'p' to NULL. */
!   n = mbsnrtowcs(wsbuf+wcnum, &p, nms, wsbuf_size-wcnum, &state);
  
!   /* Compensate for taking single byte on wcs conversion failure above. */
!   if (wcslength == 1 && (n == 0 || n == (size_t)-1))
!   {
! state = tmp_state;
! p = tmp_p;
! wsbuf[wcnum++] = *p++;
!   }
!   else
! wcnum += wcslength;
  
if (mbsinit (&state) && (p != NULL) && (*p == '\\'))
***
*** 231,236 
 of DESTP and INDICESP are NULL. */
  
- #define WSBUF_INC 32
- 
  size_t
  xdupmbstowcs (destp, indicesp, src)
--- 253,256 
*** ../bash-4.2-patched/lib/glob/glob.c 2009-11-14 18:39:30.0 -0500
--- lib/glob/glob.c 2012-07-07 12:09:56.0 -0400
***
*** 201,206 
size_t pat_n, dn_n;
  
pat_n = xdupmbstowcs (&pat_wc, NULL, pat);
!   dn_n = xdupmbstowcs (&dn_wc, NULL, dname);
  
ret = 0;
--- 201,209 
size_t pat_n, dn_n;
  
+   pat_wc = dn_wc = (wchar_t *)NULL;
+ 
pat_n = xdupmbstowcs (&pat_wc, NULL, pat);
!   if (pat_n != (size_t)-1)
! dn_n = xdupmbstowcs (&dn_wc, NULL, dname);
  
ret = 0;
***
*** 222,225 
--- 225,230 
ret = 1;
  }
+   else
+ ret = skipname (pat, dname, flags);
  
FREE (pat_wc);
***
*** 267,272 
n = xdupmbstowcs (&wpathname, NULL, pathname);
if (n == (size_t) -1)
! /* Something wrong. */
! return;
orig_wpathname = wpathname;
  
--- 272,280 
n = xdupmbstowcs (&wpathname, NULL, pathname);
if (n == (size_t) -1)
! {
!   /* Something wrong.  Fall back to single-byte */
!   udequote_pathname (pathname);
!   return;
! }
orig_wpathname = wpathname;
  
*** ../bash-4.2-patched/patchlevel.hSat Jun 12 20:14:48 2010
--- patchlevel.hThu Feb 24 21:41:34 2011
***

Bash-4.2 Official Patch 31

2012-07-10 Thread Chet Ramey
 BASH PATCH REPORT
 =

Bash-Release:   4.2
Patch-ID:   bash42-031

Bug-Reported-by:Max Horn 
Bug-Reference-ID:   <20cc5c60-07c3-4e41-9817-741e48d40...@quendi.de>
Bug-Reference-URL:  
http://lists.gnu.org/archive/html/bug-readline/2012-06/msg5.html

Bug-Description:

A change between bash-4.1 and bash-4.2 to prevent the readline input hook
from being called too frequently had the side effect of causing delays
when reading pasted input on systems such as Mac OS X.  This patch fixes
those delays while retaining the bash-4.2 behavior.

Patch (apply with `patch -p0'):

*** ../bash-4.2-patched/lib/readline/input.c2010-05-30 18:33:01.0 
-0400
--- lib/readline/input.c2012-06-25 21:08:42.0 -0400
***
*** 410,414 
  rl_read_key ()
  {
!   int c;
  
rl_key_sequence_length++;
--- 412,416 
  rl_read_key ()
  {
!   int c, r;
  
rl_key_sequence_length++;
***
*** 430,441 
  while (rl_event_hook)
{
! if (rl_gather_tyi () < 0) /* XXX - EIO */
{
  rl_done = 1;
  return ('\n');
}
  RL_CHECK_SIGNALS ();
- if (rl_get_char (&c) != 0)
-   break;
  if (rl_done)  /* XXX - experimental */
return ('\n');
--- 432,447 
  while (rl_event_hook)
{
! if (rl_get_char (&c) != 0)
!   break;
!   
! if ((r = rl_gather_tyi ()) < 0)   /* XXX - EIO */
{
  rl_done = 1;
  return ('\n');
}
+ else if (r == 1)  /* read something */
+   continue;
+ 
  RL_CHECK_SIGNALS ();
  if (rl_done)  /* XXX - experimental */
return ('\n');
*** ../bash-4.2-patched/patchlevel.hSat Jun 12 20:14:48 2010
--- patchlevel.hThu Feb 24 21:41:34 2011
***
*** 26,30 
 looks for to find the patch level (for the sccs version string). */
  
! #define PATCHLEVEL 30
  
  #endif /* _PATCHLEVEL_H_ */
--- 26,30 
 looks for to find the patch level (for the sccs version string). */
  
! #define PATCHLEVEL 31
  
  #endif /* _PATCHLEVEL_H_ */

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, ITS, CWRUc...@case.eduhttp://cnswww.cns.cwru.edu/~chet/



Bash-4.2 Official Patch 32

2012-07-10 Thread Chet Ramey
 BASH PATCH REPORT
 =

Bash-Release:   4.2
Patch-ID:   bash42-032

Bug-Reported-by:Ruediger Kuhlmann 
Bug-Reference-ID:   

Bug-Reference-URL:  
http://lists.gnu.org/archive/html/bug-bash/2012-05/msg00010.html

Bug-Description:

Bash-4.2 has problems with DEL characters in the expanded value of variables
used in the same quoted string as variables that expand to nothing.

Patch (apply with `patch -p0'):

*** ../bash-20120427/subst.c2012-04-22 16:19:10.0 -0400
--- subst.c 2012-05-07 16:06:35.0 -0400
***
*** 8152,8155 
--- 8152,8163 
  dispose_word_desc (tword);
  
+ /* Kill quoted nulls; we will add them back at the end of
+expand_word_internal if nothing else in the string */
+ if (had_quoted_null && temp && QUOTED_NULL (temp))
+   {
+ FREE (temp);
+ temp = (char *)NULL;
+   }
+ 
  goto add_string;
  break;
***
*** 8556,8560 
if (quoted & (Q_HERE_DOCUMENT|Q_DOUBLE_QUOTES))
tword->flags |= W_QUOTED;
!   if (had_quoted_null)
tword->flags |= W_HASQUOTEDNULL;
list = make_word_list (tword, (WORD_LIST *)NULL);
--- 8564,8568 
if (quoted & (Q_HERE_DOCUMENT|Q_DOUBLE_QUOTES))
tword->flags |= W_QUOTED;
!   if (had_quoted_null && QUOTED_NULL (istring))
tword->flags |= W_HASQUOTEDNULL;
list = make_word_list (tword, (WORD_LIST *)NULL);
***
*** 8587,8591 
  if (word->flags & W_NOEXPAND)
tword->flags |= W_NOEXPAND;
! if (had_quoted_null)
tword->flags |= W_HASQUOTEDNULL;/* XXX */
  list = make_word_list (tword, (WORD_LIST *)NULL);
--- 8595,8599 
  if (word->flags & W_NOEXPAND)
tword->flags |= W_NOEXPAND;
! if (had_quoted_null && QUOTED_NULL (istring))
tword->flags |= W_HASQUOTEDNULL;/* XXX */
  list = make_word_list (tword, (WORD_LIST *)NULL);
*** ../bash-4.2-patched/patchlevel.hSat Jun 12 20:14:48 2010
--- patchlevel.hThu Feb 24 21:41:34 2011
***
*** 26,30 
 looks for to find the patch level (for the sccs version string). */
  
! #define PATCHLEVEL 31
  
  #endif /* _PATCHLEVEL_H_ */
--- 26,30 
 looks for to find the patch level (for the sccs version string). */
  
! #define PATCHLEVEL 32
  
  #endif /* _PATCHLEVEL_H_ */

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, ITS, CWRUc...@case.eduhttp://cnswww.cns.cwru.edu/~chet/



Bash-4.2 Official Patch 33

2012-07-10 Thread Chet Ramey
 BASH PATCH REPORT
 =

Bash-Release:   4.2
Patch-ID:   bash42-033

Bug-Reported-by:David Leverton 
Bug-Reference-ID:   <4fcce737.1060...@googlemail.com>
Bug-Reference-URL:

Bug-Description:

Bash uses a static buffer when expanding the /dev/fd prefix for the test
and conditional commands, among other uses, when it should use a dynamic
buffer to avoid buffer overflow.

Patch (apply with `patch -p0'):

*** ../bash-4.2-patched/lib/sh/eaccess.c2011-01-08 20:50:10.0 
-0500
--- lib/sh/eaccess.c2012-06-04 21:06:43.0 -0400
***
*** 83,86 
--- 83,88 
   struct stat *finfo;
  {
+   static char *pbuf = 0;
+ 
if (*path == '\0')
  {
***
*** 107,111 
   On most systems, with the notable exception of linux, this is
   effectively a no-op. */
!   char pbuf[32];
strcpy (pbuf, DEV_FD_PREFIX);
strcat (pbuf, path + 8);
--- 109,113 
   On most systems, with the notable exception of linux, this is
   effectively a no-op. */
!   pbuf = xrealloc (pbuf, sizeof (DEV_FD_PREFIX) + strlen (path + 8));
strcpy (pbuf, DEV_FD_PREFIX);
strcat (pbuf, path + 8);
*** ../bash-4.2-patched/patchlevel.hSat Jun 12 20:14:48 2010
--- patchlevel.hThu Feb 24 21:41:34 2011
***
*** 26,30 
 looks for to find the patch level (for the sccs version string). */
  
! #define PATCHLEVEL 32
  
  #endif /* _PATCHLEVEL_H_ */
--- 26,30 
 looks for to find the patch level (for the sccs version string). */
  
! #define PATCHLEVEL 33
  
  #endif /* _PATCHLEVEL_H_ */

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, ITS, CWRUc...@case.eduhttp://cnswww.cns.cwru.edu/~chet/



Bash-4.2 Official Patch 34

2012-07-10 Thread Chet Ramey
 BASH PATCH REPORT
 =

Bash-Release:   4.2
Patch-ID:   bash42-034

Bug-Reported-by:"Davide Brini" 
Bug-Reference-ID:   <20120604164154.69781ec...@imaps.oficinas.atrapalo.com>
Bug-Reference-URL:  
http://lists.gnu.org/archive/html/bug-bash/2012-06/msg00030.html

Bug-Description:

In bash-4.2, the history code would inappropriately add a semicolon to
multi-line compound array assignments when adding them to the history.

Patch (apply with `patch -p0'):

*** ../bash-4.2-patched/parse.y 2011-11-21 18:03:36.0 -0500
--- parse.y 2012-06-07 12:48:47.0 -0400
***
*** 4900,4905 
--- 4916,4924 
return (current_command_line_count == 2 ? "\n" : "");
  }
  
+   if (parser_state & PST_COMPASSIGN)
+ return (" ");
+ 
/* First, handle some special cases. */
/*(*/
/* If we just read `()', assume it's a function definition, and don't
*** ../bash-4.2-patched/patchlevel.hSat Jun 12 20:14:48 2010
--- patchlevel.hThu Feb 24 21:41:34 2011
***
*** 26,30 
 looks for to find the patch level (for the sccs version string). */
  
! #define PATCHLEVEL 33
  
  #endif /* _PATCHLEVEL_H_ */
--- 26,30 
 looks for to find the patch level (for the sccs version string). */
  
! #define PATCHLEVEL 34
  
  #endif /* _PATCHLEVEL_H_ */

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, ITS, CWRUc...@case.eduhttp://cnswww.cns.cwru.edu/~chet/



Bash-4.2 Official Patch 35

2012-07-10 Thread Chet Ramey
 BASH PATCH REPORT
 =

Bash-Release:   4.2
Patch-ID:   bash42-035

Bug-Reported-by:Dan Douglas 
Bug-Reference-ID:   <2766482.Ksm3GrSoYi@smorgbox>
Bug-Reference-URL:  
http://lists.gnu.org/archive/html/bug-bash/2012-06/msg00071.html

Bug-Description:

When given a number of lines to read, `mapfile -n lines' reads one too many.

Patch (apply with `patch -p0'):

*** ../bash-4.2-patched/builtins/mapfile.def2010-05-29 22:09:47.0 
-0400
--- builtins/mapfile.def2012-06-20 09:48:33.0 -0400
***
*** 196,206 
interrupt_immediately++;
for (array_index = origin, line_count = 1; 
!zgetline (fd, &line, &line_length, unbuffered_read) != -1;
!array_index++, line_count++) 
  {
-   /* Have we exceeded # of lines to store? */
-   if (line_count_goal != 0 && line_count > line_count_goal) 
-   break;
- 
/* Remove trailing newlines? */
if (flags & MAPF_CHOP)
--- 196,202 
interrupt_immediately++;
for (array_index = origin, line_count = 1; 
!   zgetline (fd, &line, &line_length, unbuffered_read) != -1;
!   array_index++) 
  {
/* Remove trailing newlines? */
if (flags & MAPF_CHOP)
***
*** 218,221 
--- 214,222 
  
bind_array_element (entry, array_index, line, 0);
+ 
+   /* Have we exceeded # of lines to store? */
+   line_count++;
+   if (line_count_goal != 0 && line_count > line_count_goal) 
+   break;
  }
  
*** ../bash-4.2-patched/patchlevel.hSat Jun 12 20:14:48 2010
--- patchlevel.hThu Feb 24 21:41:34 2011
***
*** 26,30 
 looks for to find the patch level (for the sccs version string). */
  
! #define PATCHLEVEL 34
  
  #endif /* _PATCHLEVEL_H_ */
--- 26,30 
 looks for to find the patch level (for the sccs version string). */
  
! #define PATCHLEVEL 35
  
  #endif /* _PATCHLEVEL_H_ */

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, ITS, CWRUc...@case.eduhttp://cnswww.cns.cwru.edu/~chet/



Bash-4.2 Official Patch 36

2012-07-10 Thread Chet Ramey
 BASH PATCH REPORT
 =

Bash-Release:   4.2
Patch-ID:   bash42-036

Bug-Reported-by:gregrwm 
Bug-Reference-ID:   

Bug-Reference-URL:  
http://lists.gnu.org/archive/html/bug-bash/2012-05/msg00108.html

Bug-Description:

Bash-4.2 produces incorrect word splitting results when expanding
double-quoted $@ in the same string as and adjacent to other variable
expansions.  The $@ should be split, the other expansions should not.

Patch (apply with `patch -p0'):

*** ../bash-4.2-patched/subst.c 2012-05-02 12:02:33.0 -0400
--- subst.c 2012-07-08 21:19:32.0 -0400
***
*** 7923,7927 
/* State flags */
int had_quoted_null;
!   int has_dollar_at;
int tflag;
int pflags; /* flags passed to param_expand */
--- 7923,7927 
/* State flags */
int had_quoted_null;
!   int has_dollar_at, temp_has_dollar_at;
int tflag;
int pflags; /* flags passed to param_expand */
***
*** 8128,8138 
*expanded_something = 1;
  
! has_dollar_at = 0;
  pflags = (word->flags & W_NOCOMSUB) ? PF_NOCOMSUB : 0;
  if (word->flags & W_NOSPLIT2)
pflags |= PF_NOSPLIT2;
  tword = param_expand (string, &sindex, quoted, expanded_something,
!  &has_dollar_at, "ed_dollar_at,
   &had_quoted_null, pflags);
  
  if (tword == &expand_wdesc_error || tword == &expand_wdesc_fatal)
--- 8128,8139 
*expanded_something = 1;
  
! temp_has_dollar_at = 0;
  pflags = (word->flags & W_NOCOMSUB) ? PF_NOCOMSUB : 0;
  if (word->flags & W_NOSPLIT2)
pflags |= PF_NOSPLIT2;
  tword = param_expand (string, &sindex, quoted, expanded_something,
!  &temp_has_dollar_at, "ed_dollar_at,
   &had_quoted_null, pflags);
+ has_dollar_at += temp_has_dollar_at;
  
  if (tword == &expand_wdesc_error || tword == &expand_wdesc_fatal)
***
*** 8275,8281 
  temp = (char *)NULL;
  
! has_dollar_at = 0;
  /* Need to get W_HASQUOTEDNULL flag through this function. */
! list = expand_word_internal (tword, Q_DOUBLE_QUOTES, 0, 
&has_dollar_at, (int *)NULL);
  
  if (list == &expand_word_error || list == &expand_word_fatal)
--- 8276,8283 
  temp = (char *)NULL;
  
! temp_has_dollar_at = 0;   /* XXX */
  /* Need to get W_HASQUOTEDNULL flag through this function. */
! list = expand_word_internal (tword, Q_DOUBLE_QUOTES, 0, 
&temp_has_dollar_at, (int *)NULL);
! has_dollar_at += temp_has_dollar_at;
  
  if (list == &expand_word_error || list == &expand_word_fatal)
*** ../bash-4.2-patched/patchlevel.hSat Jun 12 20:14:48 2010
--- patchlevel.hThu Feb 24 21:41:34 2011
***
*** 26,30 
 looks for to find the patch level (for the sccs version string). */
  
! #define PATCHLEVEL 35
  
  #endif /* _PATCHLEVEL_H_ */
--- 26,30 
 looks for to find the patch level (for the sccs version string). */
  
! #define PATCHLEVEL 36
  
  #endif /* _PATCHLEVEL_H_ */

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, ITS, CWRUc...@case.eduhttp://cnswww.cns.cwru.edu/~chet/



retrun value of buildin (( )) / GNU bash, version 4.2.24(1)-release (x86_64-pc-linux-gnu)

2012-07-10 Thread Orlob Martin (EXT)
Hallo,

I was using the build in (( )) function for  count up an index. I think I found 
a bug in GNU bash, version 4.2.24(1)-release (x86_64-pc-linux-gnu).

The (( )) function is working fine, but the corresponding return value does not 
match.
 Check following small example (have the focus on $?)

--SCRIPT START-
#!/bin/bash

index=-3
for a in 1 2 3 4 5 6 7  ; do
echo "Index before: $index"
(( index++ ))
  echo "Return value: $?"
  echo "Index after: $index"
  echo ""
done
--SCRIPT END--

OUTPUT is:


Index before: -3
Return value: 0
Index after: -2

Index before: -2
Return value: 0
Index after: -1

Index before: -1
Return value: 0
Index after: 0

Index before: 0
Return value: 1 <-- ?BUG? The index was counted up correctly, from 0 to 1, 
but return value of (( ))-function is "1"
Index after: 1

Index before: 1
Return value: 0
Index after: 2

Index before: 2
Return value: 0
Index after: 3

Index before: 3
Return value: 0
Index after: 4


Cheers,

Martin







--
Martin Orlob - Systemintegrator

Im Auftrag der
e.solutions GmbH
GVZ Halle N West / Eingang A,
Pascalstraße 5, 85057 Ingolstadt, Germany

Registered Office:
Pascalstr. 5, 85057 Ingolstadt, Germany

Phone +49-8458-3332-702
Fax +49-8458-3332-20130
mailto: 
extern.martin.or...@esolutions.de

e.solutions GmbH
Managing Directors Uwe Reder, Dr. Riclef Schmidt-Clausen
Register Court Ingolstadt HRB 5221



Re: retrun value of buildin (( )) / GNU bash, version 4.2.24(1)-release (x86_64-pc-linux-gnu)

2012-07-10 Thread Roman Rakus

On 07/10/2012 05:32 PM, Orlob Martin (EXT) wrote:

Hallo,

I was using the build in (( )) function for  count up an index. I think I found 
a bug in GNU bash, version 4.2.24(1)-release (x86_64-pc-linux-gnu).

((expression)) is one of Compound Commands (not builtin nor function).
Quoting the manual page:
((expression))
The expression is evaluated according to the rules described
below under ARITHMETIC EVALUATION. If the value of the expres‐
sion is non-zero, the return status is 0; otherwise the return
status is 1. This is exactly equivalent to let "expression".

See also a comment below inline.


The (( )) function is working fine, but the corresponding return value does not 
match.
  Check following small example (have the focus on $?)

--SCRIPT START-
#!/bin/bash

index=-3
for a in 1 2 3 4 5 6 7  ; do
 echo "Index before: $index"
 (( index++ ))
   echo "Return value: $?"
   echo "Index after: $index"
   echo ""
done
--SCRIPT END--

OUTPUT is:


Index before: -3
Return value: 0
Index after: -2

Index before: -2
Return value: 0
Index after: -1

Index before: -1
Return value: 0
Index after: 0

Index before: 0
Return value: 1<-- ?BUG? The index was counted up correctly, from 0 to 1, but return 
value of (( ))-function is "1"
No, works like intended. index value is 0 (zero) and thus return value 
of (( )) is 1. And the value of index is post-incremented.

Index after: 1

Index before: 1
Return value: 0
Index after: 2

Index before: 2
Return value: 0
Index after: 3

Index before: 3
Return value: 0
Index after: 4


Cheers,

Martin







--
Martin Orlob - Systemintegrator

Im Auftrag der
e.solutions GmbH
GVZ Halle N West / Eingang A,
Pascalstraße 5, 85057 Ingolstadt, Germany

Registered Office:
Pascalstr. 5, 85057 Ingolstadt, Germany

Phone +49-8458-3332-702
Fax +49-8458-3332-20130
mailto: 
extern.martin.or...@esolutions.de

e.solutions GmbH
Managing Directors Uwe Reder, Dr. Riclef Schmidt-Clausen
Register Court Ingolstadt HRB 5221