/rusxmms/librcc

To get this branch, use:
bzr branch http://suren.me/webbzr/rusxmms/librcc

« back to all changes in this revision

Viewing changes to src/opt.c

  • Committer: Suren A. Chilingaryan
  • Date: 2005-07-02 05:08:36 UTC
  • Revision ID: Arch-1:ds@dside.dyndns.org--darksoft-2004%librcc--main--0.1--patch-3
02.07.2005

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#include <stdio.h>
 
2
 
 
3
#include "internal.h"
 
4
#include "opt.h"
 
5
 
 
6
rcc_option_value rccConfigGetOption(rcc_context ctx, rcc_option option) {
 
7
    if ((!ctx)||(option<0)||(option>=RCC_MAX_OPTIONS)) return -1;
 
8
    
 
9
    return ctx->options[option];
 
10
}
 
11
 
 
12
int rccConfigSetOption(rcc_context ctx, rcc_option option, rcc_option_value value) {
 
13
    if ((!ctx)||(option>=RCC_MAX_OPTIONS)) return -1;
 
14
 
 
15
    if (ctx->options[option] != value) {
 
16
        ctx->configure = 1;
 
17
        ctx->options[option]=value;
 
18
    }
 
19
    
 
20
    return 0;
 
21
}