Questions tagged [invalid-argument]
263 questions
1
vote
0 answers
Invalid arguments istream read
I want to read out a file using istream::read(). However I get the error "Invalid arguments" when trying to compile in Eclipse CDT.
Code looks like this
int main(){
std::ifstream list("list", std::fstream::in);
if( list.is_open() ){
…

dspName234
- 11
- 1
1
vote
2 answers
Exception: Invalid_argument "String.sub / Bytes.sub" ocaml
let separate = fun formula ->
let rec aux = fun counter begin size ->
match formula.[begin + size] with
| '(' -> aux (counter + 1) begin (size + 1)
| ')' -> if (counter - 1) = 0 then ((String.sub formula (begin + 1) size),…

Antonio Machado
- 61
- 2
- 3
1
vote
2 answers
Invalid requirement, parse error at "''"
I'm trying to connect to host by different threads in python but getting error sometimes(1 times in 25 times execution)
I have seen similar threads and hoped to update pip to 8.1.1 will solve this but did not solve though.
code snippet:
def…

saketh modugu
- 53
- 1
- 5
1
vote
2 answers
Opening Japanese-named files in Lua
I have bunch of XML files named in Japanese. I use Lua to read them and put the necessary informations into tables. I could open files named only in a single kanji like 名.xml, but for multiple kanjis like 名前.xml it was contrawise. Before I ran the…

Dousea
- 15
- 6
1
vote
1 answer
Adding a custom chain to OUTPUT using libiptc
I'm trying to achieve the following iptable command using libiptc, but cannot find any examples of how to do this.
iptables -A OUTPUT -j my_outbound_rules
I've tried using the following code:
int addChainToBuiltin(const char *_pChain, const char…

linusoft
- 33
- 4
1
vote
1 answer
Invalid argument supplied for foreach() in Wordpress. No clue
i'm stuck with a "Warning: Invalid argument supplied for foreach() in header.php on line 215" in a site i'm building and don't have the slightest clue. It must have something to do with the fact that i suck at coding.
It reads as follows. Line 215…

John Page
- 11
- 1
- 1
- 2
1
vote
1 answer
Python:Storing path in variable; Argument Error
path = input("Enter the path")
book = xlrd.open_workbook(path)
After giving path and running program, I am getting the following error:
OSError: [Errno 22] Invalid argument: '"D:\\\shreyatest1.xlsx"'
Path is: "D:\\shreyatest1.xlsx"

Shreya Gaddam
- 33
- 1
- 8
1
vote
2 answers
RSpec requests an access token from Doorkeeper and then always gets invalid_grant error
When I testing the procedure of requesting an access token, which is part of authorize flow, from Doorkeeper gem at localhost side through RSpec with Ruby on Rails, Devise, Grape and Wine_bouncer, RSpec always receives a 401 response from…

Howardsun
- 116
- 3
- 12
1
vote
2 answers
Why do I get "Invalid args" at runtime with this code?
I've got this code to conditionally format a cell after it has been assigned to, based on the value it contains:
var avgWeeklyDeliveriesCell = (Excel.Range)_xlSheet.Cells[curDelPerfRow,
…

B. Clay Shannon-B. Crow Raven
- 8,547
- 144
- 472
- 862
1
vote
1 answer
Invalid identifier in an Oracle SQL query
I'm kind of a beginner in programming and I can't succeed in running this query on Oracle SQL.
What I would like to achieve is selecting the id and the names (aya_id, aya_name) from a table AYANTDROIT, and for each of these ids another name which…

Jérémy Thizy
- 13
- 4
1
vote
1 answer
bind() Failed: Invalid argument
First try with socket prog. any help why I get this error? This my server side code, till the part of bind (exluding listen etc)
thnx in advance
int main(){
unsigned int s; //returned by socket()
int port; //port number
int n; //fore…

George
- 52
- 8
1
vote
1 answer
IOError: [Errno 22] Invalid Argument with clock() being passed in
I have not had much luck hunting for finding a good explanation of what invalid argument errors are and what would cause them.
My current sample I am working with is
import sys
mylog="mylog.log"
sys.stdout = open(mylog,'w')
#lots of…

Tim McJilton
- 6,884
- 6
- 25
- 27
1
vote
2 answers
Swift setsockopt SOL_SOCKET SO_RCVTIMEO gets invalid argument
The following playground demonstrates the problem.
//: Playground - noun: a place where people can play
import Foundation
var s = socket(AF_INET, SOCK_STREAM, 0)
var tv = timeval()
tv.tv_sec = 3
tv.tv_usec = 100000
let…

Jim
- 9
- 1
- 4
1
vote
1 answer
aio_write and memset invalid argument and Segmentation Fault (core dumped)
I'm trying to fill my file with 'a' characters and I need tu use aio_write. Here's my writing function
int da_aio_write(const int d, struct aiocb *aiorp, void *buf, const int count){
int rv = 0;
// memset( (void *)aiorp, 'a', sizeof( struct…

David
- 3,055
- 4
- 30
- 73
1
vote
3 answers
invalid type argument of '->' (have 'int')
I get the error reported below while I am compiling my code. Could you please correct me where I mistaken?
invalid type argument of -> (have int)
My code is as follows:
#include
#include
#include
#include…

SPradhan
- 67
- 1
- 8