ReactOS Fundraising Campaign 2012
 
€ 4,410 / € 30,000

Information | Donate

Home | Info | Community | Development | myReactOS | Contact Us

  1. Home
  2. Community
  3. Development
  4. myReactOS
  5. Fundraiser 2012

  1. Main Page
  2. Alphabetical List
  3. Data Structures
  4. Directories
  5. File List
  6. Data Fields
  7. Globals
  8. Related Pages

ReactOS Development > Doxygen

static void handleURI ( const char str) [static]

Definition at line 23 of file testURI.c.

Referenced by main().

                                       {
    int ret;
    xmlURIPtr uri;
    xmlChar *res = NULL, *parsed = NULL;

    uri = xmlCreateURI();

    if (base == NULL) {
    ret = xmlParseURIReference(uri, str);
    if (ret != 0)
        printf("%s : error %d\n", str, ret);
    else {
        if (debug) {
            if (uri->scheme) printf("scheme: %s\n", uri->scheme);
            if (uri->opaque) printf("opaque: %s\n", uri->opaque);
            if (uri->authority) printf("authority: %s\n", uri->authority);
            if (uri->server) printf("server: %s\n", uri->server);
            if (uri->user) printf("user: %s\n", uri->user);
            if (uri->port != 0) printf("port: %d\n", uri->port);
            if (uri->path) printf("path: %s\n", uri->path);
            if (uri->query) printf("query: %s\n", uri->query);
            if (uri->fragment) printf("fragment: %s\n", uri->fragment);
            if (uri->query_raw) printf("query_raw: %s\n", uri->query_raw);
            if (uri->cleanup != 0) printf("cleanup\n");
        }
        xmlNormalizeURIPath(uri->path);
        if (escape != 0) {
        parsed = xmlSaveUri(uri);
        res = xmlURIEscape(parsed);
        printf("%s\n", (char *) res);

        } else {
        xmlPrintURI(stdout, uri);
        printf("\n");
        }
    }
    } else {
    res = xmlBuildURI((xmlChar *)str, (xmlChar *) base);
    if (res != NULL) {
        printf("%s\n", (char *) res);
    }
    else
        printf("::ERROR::\n");
    }
    if (res != NULL)
    xmlFree(res);
    if (parsed != NULL)
    xmlFree(parsed);
    xmlFreeURI(uri);
}

Generated on Sat May 26 2012 06:01:58 for ReactOS by doxygen 1.7.6.1

ReactOS is a registered trademark or a trademark of ReactOS Foundation in the United States and other countries.