source: rtems/cpukit/libcsupport/src/assocptrbyremote.c @ da154e14

4.115
Last change on this file since da154e14 was 9b4422a2, checked in by Joel Sherrill <joel.sherrill@…>, on 05/03/12 at 15:09:24

Remove All CVS Id Strings Possible Using a Script

Script does what is expected and tries to do it as
smartly as possible.

+ remove occurrences of two blank comment lines

next to each other after Id string line removed.

+ remove entire comment blocks which only exited to

contain CVS Ids

+ If the processing left a blank line at the top of

a file, it was removed.

  • Property mode set to 100644
File size: 531 bytes
Line 
1/*
2 * assoc.c
3 *      rtems assoc routines
4 */
5
6#if HAVE_CONFIG_H
7#include "config.h"
8#endif
9
10#define INSIDE_ASSOC
11
12#include <rtems.h>
13#include <rtems/assoc.h>
14
15#include <string.h>             /* strcat, strcmp */
16
17const rtems_assoc_t *rtems_assoc_ptr_by_remote(
18  const rtems_assoc_t *ap,
19  uint32_t       remote_value
20)
21{
22  const rtems_assoc_t *default_ap = 0;
23
24  if (rtems_assoc_is_default(ap))
25    default_ap = ap++;
26
27  for ( ; ap->name; ap++)
28    if (ap->remote_value == remote_value)
29      return ap;
30
31  return default_ap;
32}
Note: See TracBrowser for help on using the repository browser.