Skip to content

Commit

Permalink
Remove redundant code and fix more format errors
Browse files Browse the repository at this point in the history
  • Loading branch information
Pratik Joseph Dabre authored and Pratik Joseph Dabre committed Aug 3, 2024
1 parent 0d5c036 commit dc5f0e2
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 69 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -435,69 +435,6 @@ int set_option(const char* name, const char* param) {
printf("ERROR: set_option not supported");
assert(0);
exit(1);
// int res = 1;
// option_t *o;
// char parse_int[15];
// char *cp;
//
// init_params(DSDGenContext& dsdGenContext);
//
// res = fnd_param(name);
// if (res == -1)
// return (res);
//
// o = &options[res];
//
// if (o->flags & OPT_NOP) {
// printf("ERROR: Cannot accept %s.\tNot Implemented!\n", o->name);
// return (0);
// }
//
// /* option is already set from the command line or hard-coded */
// /* and doesn't allow multiple settings */
//
// switch (o->flags & TYPE_MASK) {
// case OPT_FLG:
// if ((param && (*param == 'Y' || *param == 'Y' || *param ==
// OPTION_START)) || (param == NULL)) { if (o->action)
// if (o->action((char
//*)o->name, NULL) < 0) usage((char
//*)o->name, "Cannot process option"); set_flg(name);
//} else clr_flg(name); res = 1;
//break; case OPT_INT: if (o->action) {
//if ((res = o->action((char *)o->name, param)) < 0)
//usage(NULL, "Bad parameter argument"); else
//sprintf(parse_int, "%d", res);
// }
// set_int(name, (o->action) ? parse_int : param);
// res = 2;
// break;
// case OPT_STR:
// if (*param == '"') {
// cp = strchr((param + 1), '"');
// if (cp == NULL) /* non-terminated string literal */
// usage(NULL, "Non-terminated string");
// *cp = '\0';
// param += 1;
// } else {
// cp = strpbrk(param, " \t\n");
// if (cp != NULL)
// *cp = '\0';
// }
// if (o->action && strlen(param))
// if (o->action((char *)o->name, param) < 0)
// usage((char *)o->name, "Cannot process option");
// set_str(name, param);
// res = 2;
// break;
// default:
// fprintf(stderr, "Invalid option/type (%d/%s)\n", o->flags &
// TYPE_MASK, o->name); exit(0); break;
// }
//
// o->flags |= OPT_SET; /* marked as set */
//
// return (res);
}

/*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@
*/
#include "w_call_center.h"

#include "append_info.h"
#include "presto_cpp/main/connectors/tpcds/dsdgen/include/dsdgen-c/append_info.h"
#include "build_support.h"
#include "columns.h"
#include "config.h"
Expand All @@ -71,8 +71,6 @@
#include <stdio.h>
#include <string.h>

#include "presto_cpp/main/connectors/tpcds/include/append_info-c.hpp"

static struct CALL_CENTER_TBL g_call_center_OldValues;

/*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ append_info* append_info_get(void* info_list, int table_id);

void append_row_start(append_info info);
void append_row_end(append_info info);
int append_info_get_NLastTable(append_info info);

void append_varchar(
int32_t column,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -115,8 +115,8 @@ char* strdup(const char*);
/* Lines added by Chuck McDevitt for WIN32 support */
#ifndef _POSIX_
#ifndef S_ISREG
#define S_ISREG(m) (((m) & _S_IFMT) == _S_IFREG)
#define S_ISFIFO(m) (((m) & _S_IFMT) == _S_IFIFO)
#define S_ISREG(m) (((m)&_S_IFMT) == _S_IFREG)
#define S_ISFIFO(m) (((m)&_S_IFMT) == _S_IFIFO)
#endif
#endif
#endif /* WIN32 */
Expand Down

0 comments on commit dc5f0e2

Please sign in to comment.